Opened 8 years ago

Closed 7 years ago

Last modified 6 years ago

#12786 closed Patch - Bug Fix (fixed)

xmltv season parsing with total seasons supplied

Reported by: Gary Buhrmaster <gary.buhrmaster@…> Owned by: Peter Bennett
Priority: minor Milestone: unknown
Component: MythTV - Mythfilldatabase Version: Master Head
Severity: medium Keywords:
Cc: Ticket locked: no

Description

xmltv season parsing with total seasons number supplied

Per the xmltv dtd, the xmltv_ns episode numbering system allows for a season [aka series], and not just an episode or part, to have two sections, one before (the value) and one after (the total) a separating '/'. Currently, from a quick scan of the code, it appears that the code would not process the season number properly if that format (season/totalSeason) was provided by the grabber.

Completely untested patch to support such grabbers:

diff --git a/mythtv/programs/mythfilldatabase/xmltvparser.cpp b/mythtv/programs/mythfilldatabase/xmltvparser.cpp
index d6799ad..547cbda 100644
--- a/mythtv/programs/mythfilldatabase/xmltvparser.cpp
+++ b/mythtv/programs/mythfilldatabase/xmltvparser.cpp
@@ -462,6 +462,7 @@ ProgInfo *XMLTVParser::parseProgram(QDomElement &element)
                     totalepisodes = episode.section('/',1,1).trimmed();
                     episode = episode.section('/',0,0).trimmed();
                     season = episodenum.section('.',0,0).trimmed();
+                    season = season.section('/',0,0).trimmed();
                     QString part(episodenum.section('.',2,2));
                     QString partnumber(part.section('/',0,0).trimmed());
                     QString parttotal(part.section('/',1,1).trimmed());

Change History (4)

comment:1 Changed 7 years ago by Peter Bennett

Owner: changed from stuartm to Peter Bennett
Status: newaccepted

I have tested this patch and it solves a problem with series id from xmltv.

comment:2 Changed 7 years ago by Gary Buhrmaster <gary.buhrmaster@…>

Resolution: fixed
Status: acceptedclosed

In 585f509dea5a8e9c7d7e213d4440ebde958e8138/mythtv:

Fix parsing of season from xmltv

Fixes #12786

Signed-off-by: Peter Bennett <pbennett@…>

comment:3 Changed 7 years ago by Gary Buhrmaster <gary.buhrmaster@…>

In e26a33c69af48399b8c52b1d76872d64a944d137/mythtv:

Fix parsing of season from xmltv

Fixes #12786

Signed-off-by: Peter Bennett <pbennett@…>
(cherry picked from commit 585f509dea5a8e9c7d7e213d4440ebde958e8138)

comment:4 Changed 6 years ago by Peter Bennett

Owner: changed from Peter Bennett to Peter Bennett
Note: See TracTickets for help on using tickets.