getFrontendData is not working when the service is not started.. so call it
[enigma2.git] / lib / python / Components / TimerSanityCheck.py
index d3857039cce00f03c6ce5ef082e24310177317a6..f9176e7871fe1684f5d828798630661a0196ba15 100644 (file)
@@ -25,7 +25,6 @@ class TimerSanityCheck:
                else:
                        self.simultimer = [ self.newtimer ]
                return self.checkTimerlist()
-               
 
        def getSimulTimerList(self):
                return self.simultimer
@@ -164,13 +163,13 @@ class TimerSanityCheck:
                                timer = self.timerlist[event[1]]
                        if event[2] == self.bflag:
                                fakeRecService = NavigationInstance.instance.recordService(timer.service_ref)
+                               fakeRecResult = fakeRecService.start(True)
                                feinfo = fakeRecService.frontendInfo().getFrontendData()
                                tunerType = feinfo.get("tuner_type")
                                tunerSlot = feinfo.get("tuner_number")
                                if event[1] == -1: # new timer
                                        newTimerTunerType = tunerType
                                        newTimerTunerSlot = tunerSlot
-                               fakeRecResult = fakeRecService.start(True)
                                overlaplist.append((fakeRecResult, timer, tunerType, tunerSlot))
                                fakeRecList.append((timer, fakeRecService))
                                if fakeRecResult:
@@ -183,6 +182,7 @@ class TimerSanityCheck:
                                        if timer == fakeRec[0]:
                                                NavigationInstance.instance.stopRecordService(fakeRec[1])
                                                fakeRecList.remove(fakeRec)
+                               del fakeRec
                                if overlaplist.count(timer):
                                        overlaplist.remove(timer)
                        else:
@@ -190,9 +190,6 @@ class TimerSanityCheck:
                        self.nrep_eventlist[idx] = (event[0],event[1],event[2],cnt,overlaplist[:]) # insert a duplicate into current overlaplist
                        idx += 1
 
-               for fakeRec in fakeRecList:
-                       NavigationInstance.instance.stopRecordService(fakeRec[1])
-
                if ConflictTimer is None: # no conflict found :)
                        return True