summaryrefslogtreecommitdiff
path: root/epgsearch.h
diff options
context:
space:
mode:
authorJasmin Jessich <jasmin@anw.at>2017-05-18 23:09:38 +0200
committerJasmin Jessich <jasmin@anw.at>2017-05-18 23:09:38 +0200
commit8c21f7d47998ffc1c2c6568226eb693b0a918c7a (patch)
tree44f2ffc9d4e8b4499955d4eca179618fc1df93cd /epgsearch.h
parent521fbcbb84720e2c70d305f04a3440c837e58eef (diff)
downloadvdr-plugin-live-8c21f7d47998ffc1c2c6568226eb693b0a918c7a.tar.gz
vdr-plugin-live-8c21f7d47998ffc1c2c6568226eb693b0a918c7a.tar.bz2
Fixed lock order in SearchResult::GetEvent
- SearchResult::GetEvent has now a new parameter Channel - Call EpgEvents::CreateEpgInfo only, if a Channel has been found.
Diffstat (limited to 'epgsearch.h')
-rw-r--r--epgsearch.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/epgsearch.h b/epgsearch.h
index 61ae2eb..95d7387 100644
--- a/epgsearch.h
+++ b/epgsearch.h
@@ -340,12 +340,12 @@ public:
time_t TimerStopTime() const { return m_timerstop; }
int TimerMode() const { return m_timerMode; }
bool operator<( SearchResult const& other ) const { return m_starttime < other.m_starttime; }
- const cEvent* GetEvent();
+ const cEvent* GetEvent(const cChannel* Channel);
- /* JJJ: Should be done with a "Channels" argument to be sure the Lock order
- * is correct; or find a better way to do this
- */
#if VDRVERSNUM >= 20301
+ /* Be careful when calling this function concerning the lock order:
+ * Timers, Channels, Recordings Schedules
+ */
const cChannel* GetChannel() { LOCK_CHANNELS_READ; return Channels->GetByChannelID(m_channel); }
#else
const cChannel* GetChannel() { return Channels.GetByChannelID(m_channel); }