Bugfix: AddSchedule not replacing DummySchedule in channels

Message ID 20060710071122.M7725@schmirler.de
State New
Headers

Commit Message

Frank Schmirler July 10, 2006, 7:11 a.m. UTC
  Hi,

since 1.3.39 there's an issue with AddSchedule. If no initial EPG information
is available for a channel, it will be associated with a DummySchedule.
AddSchedule does not replace it when a schedule becomes available later. A
simple fix would be:


AddSchedule is only used by the schedule Read functions, so only file or SVDRP
based EPG imports are affected.

Cheers,
Frank
  

Patch

--- epg.c.orig  2006-07-09 00:05:37.118736336 +0200
+++ epg.c       2006-07-09 00:10:05.370955800 +0200
@@ -1023,6 +1023,9 @@ 
   if (!p) {
      p = new cSchedule(ChannelID);
      Add(p);
+     cChannel *channel = Channels.GetByChannelID(ChannelID);
+     if (channel)
+        channel->schedule = p;
      }
   return p;
 }