From 7233a6368051c0dcff527fece6ddcfaa2740a9de Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Fri, 1 Nov 2002 11:11:20 +0100 Subject: [PATCH] Fixed the EPG scanner, which broke 'Transfer Mode' as soon as it kicked in --- CONTRIBUTORS | 2 ++ HISTORY | 2 ++ device.c | 6 +++--- device.h | 4 ++-- eitscan.c | 4 ++-- 5 files changed, 11 insertions(+), 7 deletions(-) diff --git a/CONTRIBUTORS b/CONTRIBUTORS index 70b0b07e..3e991c19 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -428,6 +428,8 @@ Oliver Endriss pressing buttons of those that have already been learned for making the remote control learn procedure accept key presses only from the current remote control + for reporting a bug in the EPG scanner, which broke 'Transfer Mode' as soon as + it kicked in Reinhard Walter Buchner for adding some satellites to 'sources.conf' diff --git a/HISTORY b/HISTORY index 9b492e53..ee422adc 100644 --- a/HISTORY +++ b/HISTORY @@ -1679,3 +1679,5 @@ Video Disk Recorder Revision History - Adjusted the INSTALL file to the 1.1.x version. - Only accepting key presses from the current remote control when learning (thanks to Oliver Endriss). +- Fixed the EPG scanner, which broke 'Transfer Mode' as soon as it kicked in + (thanks to Oliver Endriss for reporting this one). diff --git a/device.c b/device.c index 2d3d1d9e..3bb68c67 100644 --- a/device.c +++ b/device.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: device.c 1.32 2002/10/26 11:43:52 kls Exp $ + * $Id: device.c 1.33 2002/11/01 11:08:57 kls Exp $ */ #include "device.h" @@ -608,10 +608,10 @@ int cDevice::ProvidesCa(int Ca) const return result ? result + others : 0; } -bool cDevice::Receiving(void) const +bool cDevice::Receiving(bool CheckAny) const { for (int i = 0; i < MAXRECEIVERS; i++) { - if (receiver[i] && receiver[i]->priority >= 0) // cReceiver with priority < 0 doesn't count + if (receiver[i] && (CheckAny || receiver[i]->priority >= 0)) // cReceiver with priority < 0 doesn't count return true; } return false; diff --git a/device.h b/device.h index 1070c52f..7ac38ab0 100644 --- a/device.h +++ b/device.h @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: device.h 1.25 2002/10/26 11:33:42 kls Exp $ + * $Id: device.h 1.26 2002/11/01 11:03:56 kls Exp $ */ #ifndef __DEVICE_H @@ -347,7 +347,7 @@ protected: public: int Ca(void) const; // Returns the ca of the current receiving session(s). - bool Receiving(void) const; + bool Receiving(bool CheckAny = false) const; // Returns true if we are currently receiving. bool AttachReceiver(cReceiver *Receiver); // Attaches the given receiver to this device. diff --git a/eitscan.c b/eitscan.c index 2a89cec9..fdcd8c3d 100644 --- a/eitscan.c +++ b/eitscan.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: eitscan.c 1.9 2002/10/19 11:48:02 kls Exp $ + * $Id: eitscan.c 1.10 2002/11/01 11:04:49 kls Exp $ */ #include "eitscan.h" @@ -55,7 +55,7 @@ void cEITScanner::Process(void) cDevice *Device = cDevice::GetDevice(i); if (Device && Device->CardIndex() < MAXDVBDEVICES) { if (Device != cDevice::PrimaryDevice() || (cDevice::NumDevices() == 1 && Setup.EPGScanTimeout && now - lastActivity > Setup.EPGScanTimeout * 3600)) { - if (!(Device->Receiving() || Device->Replaying())) { + if (!(Device->Receiving(true) || Device->Replaying())) { int oldCh = lastChannel; int ch = oldCh + 1; while (ch != oldCh) {