diff options
-rw-r--r-- | HISTORY | 1 | ||||
-rw-r--r-- | eit.c | 10 | ||||
-rw-r--r-- | eit.h | 3 |
3 files changed, 12 insertions, 2 deletions
@@ -2164,3 +2164,4 @@ Video Disk Recorder Revision History that are currently not transmitting (thanks to Marcel Wiesweg for reporting this one). - Fixed setting the locking pid after a timed wait (thanks to Andreas Schultz). +- Avoiding spurious section filter settings after a channel switch. @@ -16,7 +16,7 @@ * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * * * - * $Id: eit.c 1.75 2003/05/11 11:25:04 kls Exp $ + * $Id: eit.c 1.76 2003/05/18 12:51:50 kls Exp $ ***************************************************************************/ #include "eit.h" @@ -1073,6 +1073,7 @@ cSIProcessor::cSIProcessor(const char *FileName) masterSIProcessor = numSIProcessors == 0; // the first one becomes the 'master' currentSource = 0; currentTransponder = 0; + statusCount = 0; pmtIndex = 0; pmtPid = 0; filters = NULL; @@ -1150,6 +1151,7 @@ const char *cSIProcessor::GetEpgDataFileName(void) void cSIProcessor::SetStatus(bool On) { LOCK_THREAD; + statusCount++; ShutDownFilters(); pmtIndex = 0; pmtPid = 0; @@ -1176,6 +1178,7 @@ void cSIProcessor::Action() time_t lastCleanup = time(NULL); time_t lastPmtScan = time(NULL); + int oldStatusCount = 0; active = true; while(active) @@ -1208,6 +1211,7 @@ void cSIProcessor::Action() } // set up pfd structures for all active filter + Lock(); pollfd pfd[MAX_FILTERS]; int NumUsedFilters = 0; for (int a = 0; a < MAX_FILTERS ; a++) @@ -1219,6 +1223,8 @@ void cSIProcessor::Action() NumUsedFilters++; } } + oldStatusCount = statusCount; + Unlock(); // wait until data becomes ready from the bitfilter if (poll(pfd, NumUsedFilters, 1000) != 0) @@ -1239,6 +1245,8 @@ void cSIProcessor::Action() //dsyslog("Received pid 0x%04X with table ID 0x%02X and length of %4d\n", pid, buf[0], seclen); cMutexLock MutexLock(&schedulesMutex); // since the xMem... stuff is not thread safe, we need to use a "global" mutex LOCK_THREAD; + if (statusCount != oldStatusCount) + break; switch (pid) { case 0x00: @@ -16,7 +16,7 @@ * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * * * - * $Id: eit.h 1.28 2003/04/21 13:22:06 kls Exp $ + * $Id: eit.h 1.29 2003/05/18 12:51:50 kls Exp $ ***************************************************************************/ #ifndef __EIT_H @@ -148,6 +148,7 @@ private: bool masterSIProcessor; int currentSource; int currentTransponder; + int statusCount; int pmtIndex; int pmtPid; SIP_FILTER *filters; |