From 45467088419644481dd62c8e65ba5b338cc2a419 Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Sun, 26 Mar 2006 13:45:17 +0200 Subject: [PATCH] Ignoring 'version' in EPG data when reading from 'epg.data' or SVDRP/PUTE --- HISTORY | 2 ++ epg.c | 6 ++---- vdr.5 | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/HISTORY b/HISTORY index aa24e7da..16b94f87 100644 --- a/HISTORY +++ b/HISTORY @@ -4447,3 +4447,5 @@ Video Disk Recorder Revision History - Fixed format string handling (thanks to Darren Salt). - The new function cDevice::ForceTransferMode() can be used to force the primary device into transfer mode (thanks to Reinhard Nissl). +- The 'version' of EPG events is now ignored when reading EPG data from 'epg.data' + or via SVDRP/PUTE to avoid problems with double EPG events. diff --git a/epg.c b/epg.c index 9141f437..1530d8d5 100644 --- a/epg.c +++ b/epg.c @@ -7,7 +7,7 @@ * Original version (as used in VDR before 1.3.0) written by * Robert Schneider and Rolf Hakenes . * - * $Id: epg.c 1.67 2006/03/25 12:48:34 kls Exp $ + * $Id: epg.c 1.68 2006/03/26 13:44:23 kls Exp $ */ #include "epg.h" @@ -320,7 +320,7 @@ bool cEvent::Read(FILE *f, cSchedule *Schedule) time_t StartTime; int Duration; unsigned int TableID = 0; - unsigned int Version = 0xFF; + unsigned int Version = 0xFF; // actual value is ignored int n = sscanf(t, "%u %ld %d %X %X", &EventID, &StartTime, &Duration, &TableID, &Version); if (n >= 3 && n <= 5) { Event = (cEvent *)Schedule->GetEvent(EventID, StartTime); @@ -331,8 +331,6 @@ bool cEvent::Read(FILE *f, cSchedule *Schedule) Event = newEvent = new cEvent(EventID); if (Event) { Event->SetTableID(TableID); - if (TableID >= 0x50) // makes sure the running status flag is set from the actual data stream - Event->SetVersion(Version); Event->SetStartTime(StartTime); Event->SetDuration(Duration); if (newEvent) diff --git a/vdr.5 b/vdr.5 index e167965a..f6fc2fd9 100644 --- a/vdr.5 +++ b/vdr.5 @@ -8,9 +8,9 @@ .\" License as specified in the file COPYING that comes with the .\" vdr distribution. .\" -.\" $Id: vdr.5 1.54 2006/02/26 14:10:00 kls Exp $ +.\" $Id: vdr.5 1.55 2006/03/26 13:42:29 kls Exp $ .\" -.TH vdr 5 "19 Feb 2006" "1.3.43" "Video Disk Recorder Files" +.TH vdr 5 "26 Mar 2006" "1.3.45" "Video Disk Recorder Files" .SH NAME vdr file formats - the Video Disk Recorder Files .SH DESCRIPTION @@ -636,7 +636,7 @@ l l. @is the time (as a time_t integer) in UTC when this event starts @is the time (in seconds) that this event will take @is a hex number that indicates the table this event is contained in (if this is left empty or 0 this event will not be overwritten or modified by data that comes from the DVB stream) - @is a hex number that indicates the event's version number inside its table (optional, only processed for table IDs smaller than 0x50) + @is a hex number that indicates the event's version number inside its table (optional, ignored when reading EPG data) @is the title of the event <short text> @is the short text of the event (typically the name of the episode etc.) <description> @is the description of the event (any '|' characters will be interpreted as newlines)