From 13672280b65e50596719e15e282e03d9ac9c5301 Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Fri, 23 Dec 2022 09:47:23 +0100 Subject: [PATCH] Fixed symmetry of Begin/EndSegmentTransfer() calls in cEIT::cEIT() --- CONTRIBUTORS | 1 + HISTORY | 4 +++- eit.c | 17 +++++++++-------- 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/CONTRIBUTORS b/CONTRIBUTORS index b392c2d0..30338f3e 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -2675,6 +2675,7 @@ J for suggesting to no longer log unaligned marks in cMarks::Align() for reporting some warnings from g++ 7.2.0 regarding fixed buffer sizes in cMenuEditTimeItem::Set() and cCountdown::Update() + for fixing symmetry of Begin/EndSegmentTransfer() calls in cEIT::cEIT() Peter Pinnau for reporting that 'uint32_t' requires including stdint.h in font.h on some systems diff --git a/HISTORY b/HISTORY index e6e2fdcc..3a7bc9cb 100644 --- a/HISTORY +++ b/HISTORY @@ -9833,7 +9833,9 @@ Video Disk Recorder Revision History - Avoiding a zero sized array in cDevice::GetDevice() (thanks to Marko Mäkelä). - Now checking the video directory after setting the user id. -2022-12-19: +2022-12-23: - Updated the Italian OSD texts (thanks to Diego Pierotto). - Fixed restoring the volume at program start (thanks to Matthias Senzel). +- Fixed symmetry of Begin/EndSegmentTransfer() calls in cEIT::cEIT() (thanks to + Jörg Wendel). diff --git a/eit.c b/eit.c index 478aeb5d..b93fcb5d 100644 --- a/eit.c +++ b/eit.c @@ -8,7 +8,7 @@ * Robert Schneider and Rolf Hakenes . * Adapted to 'libsi' for VDR 1.3.0 by Marcel Wiesweg . * - * $Id: eit.c 5.5 2022/11/22 14:33:48 kls Exp $ + * $Id: eit.c 5.6 2022/12/23 09:47:23 kls Exp $ */ // The various ways in which broadcasters handle (or screw up) their EPG: @@ -115,6 +115,14 @@ cEIT::cEIT(cEitTablesHash &EitTablesHash, int Source, u_char Tid, const u_char * return; } + cSchedule *pSchedule = (cSchedule *)Schedules->GetSchedule(Channel, true); + + if (pSchedule->OnActualTp(Tid) && (Tid & 0xF0) == 0x60) { + SchedulesStateKey.Remove(false); + ChannelsStateKey.Remove(false); + return; + } + if (!EpgHandlers.BeginSegmentTransfer(Channel)) { SchedulesStateKey.Remove(false); ChannelsStateKey.Remove(false); @@ -123,13 +131,6 @@ cEIT::cEIT(cEitTablesHash &EitTablesHash, int Source, u_char Tid, const u_char * bool ChannelsModified = false; bool handledExternally = EpgHandlers.HandledExternally(Channel); - cSchedule *pSchedule = (cSchedule *)Schedules->GetSchedule(Channel, true); - - if (pSchedule->OnActualTp(Tid) && (Tid & 0xF0) == 0x60) { - SchedulesStateKey.Remove(false); - ChannelsStateKey.Remove(false); - return; - } bool Empty = true; bool Modified = false;