From 935840d74b9af4fa9fac5a882d436075fc188fa8 Mon Sep 17 00:00:00 2001 From: Midas Date: Mon, 9 Aug 2010 22:14:55 +0200 Subject: Bugfix. Logging prevented blocking ;) Fixed compiler warning. --- block.c | 13 ++++++++++--- status.c | 5 ++++- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/block.c b/block.c index abf54fa..eb932a0 100644 --- a/block.c +++ b/block.c @@ -137,8 +137,14 @@ bool cPluginBlock::SetupParse(const char *Name, const char *Value) void cPluginBlock::MainThreadHook() { - if (cSetupBlock::DetectionMethod!=1) return;//other detection method active in setup - + if (cSetupBlock::DetectionMethod!=1) + { +#ifdef LOGGING + dsyslog("plugin-block: MainThreadHook returned because other detection method active in setup"); +#endif + return;//other detection method active in setup + } + if (cEventBlock::ReplayingRecording) //no block events on the underlying channel processed - user watches recording { #ifdef LOGGING @@ -158,7 +164,6 @@ void cPluginBlock::MainThreadHook() temp_replaying_recording=false; dsyslog("plugin-block: replay of recording ended. Resuming detection mode."); } - return; } #endif @@ -170,6 +175,7 @@ void cPluginBlock::MainThreadHook() #endif return; //switch in progress } + const cChannel *channel=Channels.GetByNumber(channelnumber); @@ -242,6 +248,7 @@ void cPluginBlock::MainThreadHook() #endif return; //current show has already been checked } + #ifdef LOGGING dsyslog("plugin-block: new EPG title detected: '%s' - comparing with '%s'",title, cEventBlock::LastTitle); #endif diff --git a/status.c b/status.c index bdc0a4b..c8b0abe 100644 --- a/status.c +++ b/status.c @@ -20,7 +20,10 @@ cStatusBlock::cStatusBlock(void): void cStatusBlock::ChannelSwitch(const cDevice *Device, int ChannelNumber) { int current_channel=cDevice::CurrentChannel(); - +#ifdef LOGGING + int device_number=Device->DeviceNumber(); +#endif + if (cSetupBlock::LastChannel==0) { #ifdef LOGGING -- cgit v1.2.3