From aacdeba5d9591a8afc5f2e0e008a3b3b9dfc3bba Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Sun, 4 Jan 2015 15:11:13 +0100 Subject: Fixed multiple OBSOLETE marks in channels that are not listed in the SDT in case "Setup/Miscellaneous/Show channel names with source" is set to "yes" --- HISTORY | 2 ++ channels.c | 5 ++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/HISTORY b/HISTORY index 5bfa4e1b..4ebfdb82 100644 --- a/HISTORY +++ b/HISTORY @@ -8329,3 +8329,5 @@ Video Disk Recorder Revision History with the OctopusNet receiver via the 'satip' plugin). - Channels that are not listed in the SDT are now only marked as OBSOLETE if "Setup/DVB/Update channels" is set to a value other than "no" or "PIDs only". +- Fixed multiple OBSOLETE marks in channels that are not listed in the SDT in case + "Setup/Miscellaneous/Show channel names with source" is set to "yes". diff --git a/channels.c b/channels.c index b0e24743..de655bec 100644 --- a/channels.c +++ b/channels.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: channels.c 3.5 2014/03/10 13:14:02 kls Exp $ + * $Id: channels.c 3.6 2015/01/04 15:02:21 kls Exp $ */ #include "channels.h" @@ -1040,8 +1040,11 @@ void cChannels::MarkObsoleteChannels(int Source, int Nid, int Tid) { for (cChannel *channel = First(); channel; channel = Next(channel)) { if (time(NULL) - channel->Seen() > CHANNELTIMEOBSOLETE && channel->Source() == Source && channel->Nid() == Nid && channel->Tid() == Tid && channel->Rid() == 0) { + bool OldShowChannelNamesWithSource = Setup.ShowChannelNamesWithSource; + Setup.ShowChannelNamesWithSource = false; if (!endswith(channel->Name(), CHANNELMARKOBSOLETE)) channel->SetName(cString::sprintf("%s %s", channel->Name(), CHANNELMARKOBSOLETE), channel->ShortName(), cString::sprintf("%s %s", CHANNELMARKOBSOLETE, channel->Provider())); + Setup.ShowChannelNamesWithSource = OldShowChannelNamesWithSource; } } } -- cgit v1.2.3