summaryrefslogtreecommitdiff
path: root/sdt.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2021-03-16 15:10:54 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2021-03-16 15:10:54 +0100
commit36a833053b4b1d51ffe51ca75d06478819e92eeb (patch)
tree5eaf3ab1e809f7c8ceeb13832629deead6dbfc0d /sdt.c
parentad35c9c2d331e8c87886ce559fe838b5ac60776b (diff)
downloadvdr-36a833053b4b1d51ffe51ca75d06478819e92eeb.tar.gz
vdr-36a833053b4b1d51ffe51ca75d06478819e92eeb.tar.bz2
Improved cSectionSyncer
Diffstat (limited to 'sdt.c')
-rw-r--r--sdt.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/sdt.c b/sdt.c
index e6a8f40f..7634761e 100644
--- a/sdt.c
+++ b/sdt.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: sdt.c 4.8 2020/06/16 14:50:07 kls Exp $
+ * $Id: sdt.c 5.1 2021/03/16 15:10:54 kls Exp $
*/
#include "sdt.h"
@@ -82,14 +82,12 @@ void cSdtFilter::Process(u_short Pid, u_char Tid, const u_char *Data, int Length
}
if (!(source && Transponder()))
return;
- if (!sectionSyncer.Sync(sdt.getVersionNumber(), sdt.getSectionNumber(), sdt.getLastSectionNumber()))
+ if (!sectionSyncer.Check(sdt.getVersionNumber(), sdt.getSectionNumber()))
return;
cStateKey StateKey;
cChannels *Channels = cChannels::GetChannelsWrite(StateKey, 10);
- if (!Channels) {
- sectionSyncer.Repeat(); // let's not miss any section of the SDT
+ if (!Channels)
return;
- }
dbgsdt("SDT: %2d %2d %2d %s %d\n", sdt.getVersionNumber(), sdt.getSectionNumber(), sdt.getLastSectionNumber(), *cSource::ToString(source), Transponder());
bool ChannelsModified = false;
SI::SDT::Service SiSdtService;
@@ -203,7 +201,7 @@ void cSdtFilter::Process(u_short Pid, u_char Tid, const u_char *Data, int Length
delete LinkChannels;
}
}
- if (sdt.getSectionNumber() == sdt.getLastSectionNumber()) {
+ if (sectionSyncer.Processed(sdt.getSectionNumber(), sdt.getLastSectionNumber())) {
if (Setup.UpdateChannels == 1 || Setup.UpdateChannels >= 3) {
ChannelsModified |= Channels->MarkObsoleteChannels(source, sdt.getOriginalNetworkId(), sdt.getTransportStreamId());
if (source != Source())