diff --git a/src/gui/channellist.cpp b/src/gui/channellist.cpp index bfa476dd6..89bfcc921 100644 --- a/src/gui/channellist.cpp +++ b/src/gui/channellist.cpp @@ -1386,6 +1386,9 @@ int CChannelList::numericZap(int key) CZapitChannel* CChannelList::getPrevNextChannel(int key, unsigned int &sl) { + if(sl >= (*chanlist).size()) + sl = (*chanlist).size()-1; + CZapitChannel* channel = (*chanlist)[sl]; int bsize = bouquetList->Bouquets.size(); int bactive = bouquetList->getActiveBouquetNumber();