From 5de35b2406bbc9eba229da69f9d27cfc217ec981 Mon Sep 17 00:00:00 2001 From: TangoCash Date: Sat, 19 Nov 2016 11:57:27 +0100 Subject: [PATCH 1/2] [timers] fix start timers Origin commit data ------------------ Branch: ni/coolstream Commit: https://github.com/neutrino-images/ni-neutrino/commit/de6f90ac2755d6bc0422c0c0f173fa8835200d9b Author: TangoCash Date: 2016-11-19 (Sat, 19 Nov 2016) ------------------ No further description and justification available within origin commit message! ------------------ This commit was generated by Migit --- src/timerd/timermanager.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/timerd/timermanager.cpp b/src/timerd/timermanager.cpp index ce6e7b4e0..9f12a5ff6 100644 --- a/src/timerd/timermanager.cpp +++ b/src/timerd/timermanager.cpp @@ -1216,7 +1216,7 @@ CTimerEvent_Record::CTimerEvent_Record(CConfigFile *config, int iId): //------------------------------------------------------------ void CTimerEvent_Record::fireEvent() { - if (adjustToCurrentEPG()) + if ((adjustToCurrentEPG()) && (alarmTime > time(NULL))) return; getEpgId(); CTimerd::RecordingInfo ri=eventInfo; @@ -1232,7 +1232,7 @@ void CTimerEvent_Record::fireEvent() //------------------------------------------------------------ void CTimerEvent_Record::announceEvent() { - if (adjustToCurrentEPG()) + if ((adjustToCurrentEPG()) && (announceTime > time(NULL))) return; Refresh(); CTimerd::RecordingInfo ri=eventInfo; @@ -1368,9 +1368,11 @@ bool CTimerEvent_Record::adjustToCurrentEPG() _stopTime += post; } - if ((_alarmTime != alarmTime) || (_announceTime != announceTime) || (_stopTime != stopTime)) + if ((_alarmTime != alarmTime) || (_announceTime != announceTime) || (_stopTime != stopTime)) { + alarmTime = _alarmTime; announceTime = _announceTime; stopTime = _stopTime; if (CTimerManager::getInstance()->adjustEvent(eventID, _announceTime, _alarmTime, _stopTime)) return true; + } return false; } From 16478a2d33aab5696070c5d3863ce349750b2097 Mon Sep 17 00:00:00 2001 From: TangoCash Date: Sat, 19 Nov 2016 18:47:35 +0100 Subject: [PATCH 2/2] deactivate timer epg autoadjust until fixed and tested Origin commit data ------------------ Branch: ni/coolstream Commit: https://github.com/neutrino-images/ni-neutrino/commit/bf2c9818b038eccff07946bd922d6e82d4eefe2e Author: TangoCash Date: 2016-11-19 (Sat, 19 Nov 2016) ------------------ No further description and justification available within origin commit message! ------------------ This commit was generated by Migit --- src/timerd/timermanager.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/timerd/timermanager.cpp b/src/timerd/timermanager.cpp index 9f12a5ff6..139ea75d3 100644 --- a/src/timerd/timermanager.cpp +++ b/src/timerd/timermanager.cpp @@ -1332,6 +1332,9 @@ void CTimerEvent_Record::Refresh() //------------------------------------------------------------ bool CTimerEvent_Record::adjustToCurrentEPG() { + if (!(access(CONFIGDIR"/.adjust", F_OK) == 0)) + return false; + if (!autoAdjustToEPG) return false;