From fed74466810d208a14771c3468c4f480e491ddee Mon Sep 17 00:00:00 2001 From: Jochen Dolze Date: Thu, 14 Jun 2012 11:14:02 +0200 Subject: Fixed xmltv eventid bug --- parse.cpp | 5 +++-- xmltv2vdr.cpp | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/parse.cpp b/parse.cpp index 45f584b..484a371 100644 --- a/parse.cpp +++ b/parse.cpp @@ -308,7 +308,7 @@ bool cParse::FetchEvent(xmlNodePtr enode, bool useeptext) char *eq=strchr((char *) pid,'='); if (eq) { - xevent.SetEventID(atol(eq+6)); + xevent.SetEventID((tEventID) atol(eq+1)); } } } @@ -407,7 +407,8 @@ bool cParse::FetchEvent(xmlNodePtr enode, bool useeptext) { if (isdigit(content[0])) { - xevent.SetEventID(atol((const char *) content)); + if (!xevent.EventID()) + xevent.SetEventID((tEventID) atol((const char *) content)); } else { diff --git a/xmltv2vdr.cpp b/xmltv2vdr.cpp index 2f2ac9e..b514818 100644 --- a/xmltv2vdr.cpp +++ b/xmltv2vdr.cpp @@ -424,7 +424,7 @@ bool cEPGHandler::SetDescription(cEvent* Event, const char* Description) if (!Description) return true; // prevent setting nothing to description int len=strlen(Description); if (!len) return true; // prevent setting nothing to description - if (strncasecmp(Event->Description(),Description,len)) + if (!strcasestr(Event->Description(),Description)) { // eit description changed -> set it tsyslog("{%5i} %schanging descr of '%s'",Event->EventID(),seth ? "*" : "", -- cgit v1.2.3