summaryrefslogtreecommitdiff
path: root/services.c
diff options
context:
space:
mode:
Diffstat (limited to 'services.c')
-rw-r--r--services.c16
1 files changed, 14 insertions, 2 deletions
diff --git a/services.c b/services.c
index c714a14..3c2dac8 100644
--- a/services.c
+++ b/services.c
@@ -145,13 +145,25 @@ std::list<std::string> cEpgsearchServiceHandler::TranslateResults(cSearchResults
eTimerMatch timerMatch;
bool hasTimer = false;
- if (Timers.GetMatch(pEvent, &timerMatch))
+#if VDRVERSNUM > 20300
+ LOCK_TIMERS_READ;
+ const cTimers *vdrtimers = Timers;
+#else
+ cTimers *vdrtimers = &Timers;
+#endif
+ if (vdrtimers->GetMatch(pEvent, &timerMatch))
hasTimer = (timerMatch == tmFull);
if (!result->search->useAsSearchTimer)
result->needsTimer = false;
- cChannel *channel = Channels.GetByChannelID(pEvent->ChannelID(), true, true);
+#if VDRVERSNUM > 20300
+ LOCK_CHANNELS_READ;
+ const cChannels *vdrchannels = Channels;
+#else
+ cChannels *vdrchannels = &Channels;
+#endif
+ const cChannel *channel = vdrchannels->GetByChannelID(pEvent->ChannelID(), true, true);
int timerMode = hasTimer?1:(result->needsTimer?2:0);
std::string title = pEvent->Title()?ReplaceAll(pEvent->Title(), "|", "!^pipe!^"):"";