From 3e03181715ab58b7230cf5dd2d9a4f02b9b5bb3c Mon Sep 17 00:00:00 2001 From: "[CST]Nicu" Date: Mon, 16 Apr 2012 16:02:20 +0300 Subject: [PATCH 1/3] changed current_is_nvod from private to protected --- src/zapit/include/zapit/zapit.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/zapit/include/zapit/zapit.h b/src/zapit/include/zapit/zapit.h index 7ff4ab190..287fb8d78 100644 --- a/src/zapit/include/zapit/zapit.h +++ b/src/zapit/include/zapit/zapit.h @@ -82,7 +82,7 @@ class CZapit : public OpenThreads::Thread TP_params TP; audio_map_t audio_map; - bool current_is_nvod; + //bool current_is_nvod; //bool standby; uint32_t lastChannelRadio; uint32_t lastChannelTV; @@ -125,6 +125,7 @@ class CZapit : public OpenThreads::Thread diseqc_t diseqcType; int video_mode; CConfigFile configfile; + bool current_is_nvod; bool standby; Zapit_config config; CZapitSdtMonitor SdtMonitor; From 42813063aa9bdc34ca1231e090a9631736c863d5 Mon Sep 17 00:00:00 2001 From: "[CST] Focus" Date: Tue, 17 Apr 2012 14:47:59 +0400 Subject: [PATCH 2/3] zapit/src/zapit.cpp: add safe-check in Stop() --- src/zapit/src/zapit.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/zapit/src/zapit.cpp b/src/zapit/src/zapit.cpp index 8eade5cef..2fc658f2f 100644 --- a/src/zapit/src/zapit.cpp +++ b/src/zapit/src/zapit.cpp @@ -2049,6 +2049,8 @@ bool CZapit::Start(Z_start_arg *ZapStart_arg) bool CZapit::Stop() { + if(!started) + return false; started = false; int ret = join(); return (ret == 0); From 016ab6c08856f66ab282f6c46b39b1aa773ad6ff Mon Sep 17 00:00:00 2001 From: "[CST] Focus" Date: Tue, 17 Apr 2012 14:51:51 +0400 Subject: [PATCH 3/3] driver/volume.cpp: comment second creation of g_Zapit, g_RCInput; Use global g_RemoteControl --- src/driver/volume.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/driver/volume.cpp b/src/driver/volume.cpp index 967469616..f0e6d69c9 100644 --- a/src/driver/volume.cpp +++ b/src/driver/volume.cpp @@ -44,16 +44,18 @@ #endif CFrameBuffer * frameBuffer; -CRemoteControl * v_RemoteControl; +extern CRemoteControl * g_RemoteControl; extern cAudio * audioDecoder; static CProgressBar *g_volscale = NULL; CVolume::CVolume() { frameBuffer = CFrameBuffer::getInstance(); +#if 0 g_Zapit = new CZapitClient; g_RCInput = new CRCInput; v_RemoteControl = new CRemoteControl; +#endif VolumeFont = SNeutrinoSettings::FONT_TYPE_INFOBAR_INFO; paintDigits = true; // For future On/Off digits paintShadow = false; // For future On/Off switch shadow @@ -256,7 +258,7 @@ void CVolume::setVolume(const neutrino_msg_t key, const bool bDoPaint, bool nowa if (msg <= CRCInput::RC_MaxRC) { int sub_chan_keybind = 0; - if (g_settings.mode_left_right_key_tv == SNeutrinoSettings::VOLUME && v_RemoteControl->subChannels.size() < 1) + if (g_settings.mode_left_right_key_tv == SNeutrinoSettings::VOLUME && g_RemoteControl->subChannels.size() < 1) sub_chan_keybind = 1; if ((msg == CRCInput::RC_plus) || (sub_chan_keybind == 1 && (msg == CRCInput::RC_right))) {