diff options
author | Frank Neumann <fnu@yavdr.org> | 2017-05-12 15:18:58 +0200 |
---|---|---|
committer | Frank Neumann <fnu@yavdr.org> | 2017-05-12 15:18:58 +0200 |
commit | 1b9fb08a555d89a3b9ec9739f2b17563afb43572 (patch) | |
tree | d01be17d0bd17336f74c92fdef94212ed33a6121 /recstatus.c | |
parent | 8ede45905dde9f4109f3d4f0d2e8cedc7beee01c (diff) | |
download | vdr-plugin-epgsearch-1b9fb08a555d89a3b9ec9739f2b17563afb43572.tar.gz vdr-plugin-epgsearch-1b9fb08a555d89a3b9ec9739f2b17563afb43572.tar.bz2 |
0002-removed-variableduplications.diff (thx TomJoad@vdr-portal.de)
Diffstat (limited to 'recstatus.c')
-rw-r--r-- | recstatus.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/recstatus.c b/recstatus.c index c53888f..794ba27 100644 --- a/recstatus.c +++ b/recstatus.c @@ -49,8 +49,7 @@ void cRecStatusMonitor::Recording(const cDevice *Device, const char *Name, const cConflictCheckThread::Init((cPluginEpgsearch*)cPluginManager::GetPlugin("epgsearch"), true); LOCK_TIMERS_READ; - const cTimers *vdrtimers = Timers; - for (const cTimer *ti = vdrtimers->First(); ti; ti = vdrtimers->Next(ti)) + for (const cTimer *ti = Timers->First(); ti; ti = Timers->Next(ti)) if (ti->Recording()) { // check if this is a new entry @@ -116,8 +115,7 @@ void cRecStatusMonitor::Recording(const cDevice *Device, const char *Name, const bool found = false; LOCK_TIMERS_READ; - const cTimers *vdrtimers = Timers; - for (const cTimer *ti = vdrtimers->First(); ti; ti = vdrtimers->Next(ti)) + for (const cTimer *ti = Timers->First(); ti; ti = Timers->Next(ti)) if (ti == tiR->timer) { found = true; @@ -134,9 +132,11 @@ void cRecStatusMonitor::Recording(const cDevice *Device, const char *Name, const // check if recording has ended before timer end bool complete = true; - LOCK_RECORDINGS_READ; - const cRecordings *vdrrecordings = Recordings; - const cRecording *pRecording = vdrrecordings->GetByName(Filename); + const cRecording *pRecording; + { + LOCK_RECORDINGS_READ; + pRecording = Recordings->GetByName(Filename); + } long timerLengthSecs = tiR->timer->StopTime()-tiR->timer->StartTime(); int recFraction = 100; if (pRecording && timerLengthSecs) |