diff --git a/src/gui/channellist.cpp b/src/gui/channellist.cpp index d6e5d4488..47e91b0ee 100644 --- a/src/gui/channellist.cpp +++ b/src/gui/channellist.cpp @@ -2002,7 +2002,6 @@ void CChannelList::paintItem(int pos, const bool firstpaint) if (frameBuffer->paintIcon(record_icon, icon_x_right - icon_w, ypos, fheight)) { offset_right += icon_w + OFFSET_INNER_MID; - icon_x_right -= icon_w + OFFSET_INNER_MID; } } diff --git a/src/gui/components/cc_frm_header.cpp b/src/gui/components/cc_frm_header.cpp index a3e26b90e..f4f10ba20 100644 --- a/src/gui/components/cc_frm_header.cpp +++ b/src/gui/components/cc_frm_header.cpp @@ -231,11 +231,10 @@ void CComponentsHeader::initIcon() cch_icon_obj->doPaintBg(false); //set corner mode of icon item - int cc_icon_corner_type = corner_type; + int cc_icon_corner_type = CORNER_LEFT; if (corner_type == CORNER_TOP_LEFT || corner_type == CORNER_TOP) cc_icon_corner_type = CORNER_TOP_LEFT; - else - cc_icon_corner_type = CORNER_LEFT; + cch_icon_obj->setCorner(corner_rad-fr_thickness, cc_icon_corner_type); //global set width of icon object @@ -335,11 +334,10 @@ void CComponentsHeader::initButtons() cch_btn_obj->addIcon(v_cch_btn); //set corner mode of button item - int cc_btn_corner_type = corner_type; + int cc_btn_corner_type = CORNER_RIGHT; if (corner_type == CORNER_TOP_RIGHT || corner_type == CORNER_TOP) cc_btn_corner_type = CORNER_TOP_RIGHT; - else - cc_btn_corner_type = CORNER_RIGHT; + cch_btn_obj->setCorner(corner_rad-fr_thickness, cc_btn_corner_type); //global adapt height @@ -412,11 +410,10 @@ void CComponentsHeader::initClock() cch_cl_obj->setClockFormat(cch_cl_format, cch_cl_sec_format); //set corner mode of button item - int cc_btn_corner_type = corner_type; + int cc_btn_corner_type = CORNER_RIGHT; if (corner_type == CORNER_TOP_RIGHT || corner_type == CORNER_TOP) cc_btn_corner_type = CORNER_TOP_RIGHT; - else - cc_btn_corner_type = CORNER_RIGHT; + cch_cl_obj->setCorner(corner_rad-fr_thickness, cc_btn_corner_type); //global adapt height diff --git a/src/neutrino.cpp b/src/neutrino.cpp index bf31092a7..7fd619cad 100644 --- a/src/neutrino.cpp +++ b/src/neutrino.cpp @@ -1615,9 +1615,6 @@ void CNeutrinoApp::channelsInit(bool bOnly) RADIObouquetList = new CBouquetList(g_Locale->getText(LOCALE_CHANNELLIST_PROVS)); RADIOfavList = new CBouquetList(g_Locale->getText(LOCALE_CHANNELLIST_FAVS)); - uint32_t i; - i = 1; - int tvi = 0, ri = 0; ZapitChannelList zapitList, webtvList; @@ -1745,7 +1742,7 @@ void CNeutrinoApp::channelsInit(bool bOnly) /* Favorites and providers bouquets */ tvi = ri = 0; if(g_bouquetManager){ - for (i = 0; i < g_bouquetManager->Bouquets.size(); i++) { + for (uint32_t i = 0; i < g_bouquetManager->Bouquets.size(); i++) { CZapitBouquet *b = g_bouquetManager->Bouquets[i]; if (!b->bHidden) { if (b->getTvChannels(zapitList) || (g_settings.show_empty_favorites && b->bUser)) { @@ -2970,7 +2967,7 @@ void CNeutrinoApp::zapTo(t_channel_id channel_id) { bool recordingStatus = CRecordManager::getInstance()->RecordingStatus(channel_id); if (!recordingStatus || (recordingStatus && CRecordManager::getInstance()->TimeshiftOnly()) || - (recordingStatus && channelList->SameTP(channel_id))) { + (recordingStatus && channelList && channelList->SameTP(channel_id))) { dvbsub_stop(); g_Zapit->zapTo_serviceID_NOWAIT(channel_id); @@ -3005,7 +3002,8 @@ void CNeutrinoApp::standbyToStandby(void) t_channel_id live_channel_id = CZapit::getInstance()->GetCurrentChannelID(); if (standby_channel_id && (live_channel_id != standby_channel_id)) { live_channel_id = standby_channel_id; - channelList->zapTo_ChannelID(live_channel_id); + if(channelList) + channelList->zapTo_ChannelID(live_channel_id); } g_Zapit->setStandby(true); g_Sectionsd->setPauseScanning(true); @@ -3430,7 +3428,7 @@ int CNeutrinoApp::handleMsg(const neutrino_msg_t _msg, neutrino_msg_data_t data) CTimerd::EventInfo * eventinfo = (CTimerd::EventInfo *) data; if (eventinfo->channel_id != CZapit::getInstance()->GetCurrentChannelID()){ if( (recordingstatus == 0) || (recordingstatus && CRecordManager::getInstance()->TimeshiftOnly()) || - (recordingstatus && channelList->SameTP(eventinfo->channel_id)) ) { + (recordingstatus && channelList && channelList->SameTP(eventinfo->channel_id)) ) { bool isTVMode = CServiceManager::getInstance()->IsChannelTVChannel(eventinfo->channel_id); dvbsub_stop(); @@ -3441,7 +3439,9 @@ int CNeutrinoApp::handleMsg(const neutrino_msg_t _msg, neutrino_msg_data_t data) else if (isTVMode && (mode != mode_tv) && (mode != mode_webtv)) { tvMode(true); } - channelList->zapTo_ChannelID(eventinfo->channel_id); + + if(channelList) + channelList->zapTo_ChannelID(eventinfo->channel_id); } } delete[] (unsigned char*) data; @@ -5042,7 +5042,7 @@ bool CNeutrinoApp::adjustToChannelID(const t_channel_id channel_id) if(!has_channel && old_mode == LIST_MODE_SAT) new_mode = LIST_MODE_ALL; - has_channel = TVallList->adjustToChannelID(channel_id); + TVallList->adjustToChannelID(channel_id); } else if(CNeutrinoApp::getInstance()->getMode() == NeutrinoMessages::mode_radio) { has_channel = RADIOfavList->adjustToChannelID(channel_id); @@ -5069,7 +5069,7 @@ bool CNeutrinoApp::adjustToChannelID(const t_channel_id channel_id) if(!has_channel && old_mode == LIST_MODE_SAT) new_mode = LIST_MODE_ALL; - has_channel = RADIOallList->adjustToChannelID(channel_id); + RADIOallList->adjustToChannelID(channel_id); } if(old_mode != new_mode) CNeutrinoApp::getInstance()->SetChannelMode(new_mode); diff --git a/src/timerd/timermanager.cpp b/src/timerd/timermanager.cpp index 74b193117..766aab532 100644 --- a/src/timerd/timermanager.cpp +++ b/src/timerd/timermanager.cpp @@ -821,7 +821,9 @@ void CTimerManager::cancelShutdownOnWakeup() { pthread_mutex_lock(&tm_eventsMutex); if (shutdown_eventID > -1) { + pthread_mutex_unlock(&tm_eventsMutex); removeEvent(shutdown_eventID); + pthread_mutex_lock(&tm_eventsMutex); shutdown_eventID = -1; } wakeup = 0; diff --git a/src/zapit/src/fastscan.cpp b/src/zapit/src/fastscan.cpp index 96e5ed532..956d294e2 100644 --- a/src/zapit/src/fastscan.cpp +++ b/src/zapit/src/fastscan.cpp @@ -293,7 +293,7 @@ _err: bool CServiceScan::ReadFstVersion(int num) { - if(num >= OPERATOR_MAX) { + if(num >= OPERATOR_MAX || num < 0) { printf("[fast scan] invalid operator %d\n", num); return false; }