From: James Hutchinson Date: Tue, 19 Oct 2021 14:35:27 +0000 (+0100) Subject: opentv: fix missing summary data on rescrape, #5995 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c6bb43d8554643a772aa40c5e56904717b55a95f;p=thirdparty%2Ftvheadend.git opentv: fix missing summary data on rescrape, #5995 Chunks of events within the OpenTV data can contain blank summaries following a re-scrape. The issue of blank summary data occurs when the event in question already exists in the guide, and upon rescrape the summary record for the event in question is procesed before the title record. In this scenario we should merge the data to avoid blanking out the summary data. --- diff --git a/src/epggrab/module/opentv.c b/src/epggrab/module/opentv.c index 308e49d8c..c76507d3a 100644 --- a/src/epggrab/module/opentv.c +++ b/src/epggrab/module/opentv.c @@ -496,12 +496,12 @@ opentv_parse_event_section_one ebc = epg_broadcast_find_by_time(ch, src, ev.start, ev.stop, 1, &save, &changes); tvhdebug(LS_OPENTV, "find by time start %"PRItime_t " stop " - "%"PRItime_t " eid %d = %p", - ev.start, ev.stop, ev.eid, ebc); + "%"PRItime_t " ch %"PRId64" eid %d = %p", + ev.start, ev.stop, ch->ch_number, ev.eid, ebc); save |= epg_broadcast_set_dvb_eid(ebc, ev.eid, &changes); } else { ebc = epg_broadcast_find_by_eid(ch, ev.eid); - tvhdebug(LS_OPENTV, "find by eid %d = %p", ev.eid, ebc); + tvhdebug(LS_OPENTV, "find by ch %"PRId64" eid %d = %p", ch->ch_number, ev.eid, ebc); if (ebc) { if (ebc->grabber != src) goto done; @@ -517,6 +517,8 @@ opentv_parse_event_section_one if (entry) { save |= opentv_do_event(mod, ebc, &entry->event, ch, lang, &changes); opentv_remove_entry(mod->sta, entry); + } else { + merge = 1; } } save |= epg_broadcast_change_finish(ebc, changes, merge);