diff -Nru vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/debian/changelog vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/debian/changelog --- vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/debian/changelog 2014-08-26 21:24:25.000000000 +0000 +++ vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/debian/changelog 2014-08-28 22:08:51.000000000 +0000 @@ -1,8 +1,8 @@ -vdr-plugin-xmltv2vdr (0.2.0pre.git20140417-0easyVDR1~trusty) trusty; urgency=high +vdr-plugin-xmltv2vdr (0.2.0pre.git20140810-0easyVDR0~trusty) trusty; urgency=high - * automatic rebuild + * new upstream version - -- easyVDR-Developer Tue, 26 Aug 2014 23:24:25 +0200 + -- easyVDR-Developer Fri, 29 Aug 2014 00:48:12 +0200 vdr-plugin-xmltv2vdr (0.2.0pre.git20140417-0easyVDR0~trusty) trusty; urgency=high @@ -216,4 +216,4 @@ * New Upstream Release * Added Build-deps libsqlite3-dev - -- Holger Schvestka Sun, 25 Mar 2012 22:32:14 +0200 + -- Holger Schvestka Sun, 25 Mar 2012 22:32:14 +0200 \ No newline at end of file diff -Nru vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/debian/patches/increase-epgdata-timeout.diff vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/debian/patches/increase-epgdata-timeout.diff --- vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/debian/patches/increase-epgdata-timeout.diff 2014-04-18 16:12:59.000000000 +0000 +++ vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/debian/patches/increase-epgdata-timeout.diff 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ -Index: vdr-plugin-xmltv2vdr-d45bad06f58853f69dde50d5014addf500fcf61a/dist/epgdata2xmltv/epgdata2xmltv.cpp -=================================================================== ---- vdr-plugin-xmltv2vdr-d45bad06f58853f69dde50d5014addf500fcf61a.orig/dist/epgdata2xmltv/epgdata2xmltv.cpp 2014-04-17 20:30:03.000000000 +0200 -+++ vdr-plugin-xmltv2vdr-d45bad06f58853f69dde50d5014addf500fcf61a/dist/epgdata2xmltv/epgdata2xmltv.cpp 2014-04-18 18:12:56.838315244 +0200 -@@ -118,7 +118,7 @@ - curl_easy_setopt(curl_handle, CURLOPT_MAXFILESIZE, 85971520); // Set maximum file size to get (bytes) - curl_easy_setopt(curl_handle, CURLOPT_NOPROGRESS, 1); // No progress meter - curl_easy_setopt(curl_handle, CURLOPT_NOSIGNAL, 1); // No signaling -- curl_easy_setopt(curl_handle, CURLOPT_TIMEOUT, 240); // Set timeout to 240 seconds -+ curl_easy_setopt(curl_handle, CURLOPT_TIMEOUT, 2400); // Set timeout to 240 seconds - curl_easy_setopt(curl_handle, CURLOPT_USERAGENT, EPGDATA2XMLTV_USERAGENT); // Some servers don't like requests that are made without a user-agent field - - ret=curl_easy_perform(curl_handle); diff -Nru vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/debian/patches/series vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/debian/patches/series --- vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/debian/patches/series 2014-04-18 16:12:33.000000000 +0000 +++ vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/debian/patches/series 2014-08-10 21:00:23.000000000 +0000 @@ -1,4 +1,3 @@ -increase-epgdata-timeout.diff makefile-for-subplugins #vdr-2.1.x-compat.patch #epgdata-timeout.diff diff -Nru vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/dist/epgdata2xmltv/epgdata2xmltv.cpp vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/dist/epgdata2xmltv/epgdata2xmltv.cpp --- vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/dist/epgdata2xmltv/epgdata2xmltv.cpp 2014-04-17 18:30:03.000000000 +0000 +++ vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/dist/epgdata2xmltv/epgdata2xmltv.cpp 2014-08-10 11:41:23.000000000 +0000 @@ -118,7 +118,7 @@ curl_easy_setopt(curl_handle, CURLOPT_MAXFILESIZE, 85971520); // Set maximum file size to get (bytes) curl_easy_setopt(curl_handle, CURLOPT_NOPROGRESS, 1); // No progress meter curl_easy_setopt(curl_handle, CURLOPT_NOSIGNAL, 1); // No signaling - curl_easy_setopt(curl_handle, CURLOPT_TIMEOUT, 240); // Set timeout to 240 seconds + curl_easy_setopt(curl_handle, CURLOPT_TIMEOUT, 300); // Set timeout to 300 seconds curl_easy_setopt(curl_handle, CURLOPT_USERAGENT, EPGDATA2XMLTV_USERAGENT); // Some servers don't like requests that are made without a user-agent field ret=curl_easy_perform(curl_handle); diff -Nru vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/import.cpp vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/import.cpp --- vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/import.cpp 2014-04-17 18:30:03.000000000 +0000 +++ vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/import.cpp 2014-08-10 11:41:23.000000000 +0000 @@ -1260,7 +1260,7 @@ bool cImport::AddShortTextFromEITDescription(cXMLTVEvent *xEvent, const char *EITDescription) { if (!g->EPDir()) return false; - int season,episode,episodeoverall; + int season=0,episode=0,episodeoverall=0; char *epshorttext=NULL; if (!cParse::FetchSeasonEpisode(cep2ascii,cutf2ascii,g->EPDir(),xEvent->Title(), NULL,EITDescription, @@ -1287,7 +1287,7 @@ if (!Event) return NULL; if (!g->EPDir()) return NULL; - int season,episode,episodeoverall; + int season=0,episode=0,episodeoverall=0; char *epshorttext=NULL,*eptitle=NULL; if (!cParse::FetchSeasonEpisode(cep2ascii,cutf2ascii,g->EPDir(),Event->Title(), Event->ShortText(),Event->Description(), diff -Nru vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/parse.cpp vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/parse.cpp --- vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/parse.cpp 2014-04-17 18:30:03.000000000 +0000 +++ vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/parse.cpp 2014-08-10 11:41:23.000000000 +0000 @@ -111,11 +111,21 @@ len=strlen(String); p=String; - // cut off " Folge XX" + // cut off " Folge XX" at end p=strstr(String," Folge "); if (p) *p=0; - if (InDescription) + bool bCutNumbers=false; + len=strlen(String); + p=String; + // cut off "Folge XX" at start + if (!strncmp(String,"Folge ",6)) + { + memmove(p,p+6,len-6); + bCutNumbers=true; + } + + if (InDescription || bCutNumbers) { // remove leading numbers (inkl. roman numerals) len=strlen(String); @@ -211,7 +221,7 @@ } closedir(dir); - int f_season=0,f_episode=0; + int f_season=Season,f_episode=Episode; size_t slen; if (ShortText) { @@ -342,20 +352,24 @@ } RemoveNonAlphaNumeric(dshorttext,!ShortText); + if (!strlen(dshorttext)) { strn0cpy(dshorttext,ShortText ? ShortText : Description,slen); // ok lets try with the original text + tsyslog("Warning: removed all characters, now using '%s'",dshorttext); } if (!ShortText) { tsyslog("trying to find shorttext for '%s', with '%s'",Title,dshorttext); } + char *line=NULL; size_t length; bool found=false; if (EPShortText) *EPShortText=NULL; size_t charlen=0; + int tmpSeason=-1,tmpEpisode=-1,tmpEpisodeOverall=-1; while (getline(&line,&length,f)!=-1) { if (line[0]=='#') continue; @@ -378,6 +392,7 @@ { strcpy(depshorttext,epshorttext); // ok lets try with the original text } + if (!strcasecmp(dshorttext,depshorttext)) { // exact match @@ -400,6 +415,9 @@ { if (*EPShortText) free(*EPShortText); *EPShortText=strdup(epshorttext); + tmpSeason=Season; + tmpEpisode=Episode; + tmpEpisodeOverall=EpisodeOverall; } charlen=dlen; found=true; @@ -439,23 +457,37 @@ tsyslog("failed to parse '%s' in '%s'",line,dirent->d_name); } } + if (tmpEpisode!=-1) + { + Season=tmpSeason; + Episode=tmpEpisode; + EpisodeOverall=tmpEpisodeOverall; + } - if ((!found) && (ShortText)) + if (!found) { - isyslog("failed to find '%s' for '%s' in eplists",ShortText,Title); - if ((f_season>0) && (f_episode>0)) + Season=0; + Episode=0; + if (ShortText) { - if (EPShortText) + isyslog("failed to find '%s' for '%s' in eplists",ShortText,Title); + if ((f_season>0) && (f_episode>0)) { - if (*EPShortText) free(*EPShortText); - *EPShortText=strdup("@"); + if (EPShortText) + { + if (*EPShortText) free(*EPShortText); + *EPShortText=strdup("@"); + } + found=true; } - found=true; } } - if ((found) && (!ShortText)) + if (found) { - tsyslog("found shorttext '%s' from description of '%s'",*EPShortText,Title); + if (!ShortText) + { + tsyslog("found shorttext '%s' with description of '%s'",*EPShortText,Title); + } } if (line) free(line); fclose(f); @@ -833,7 +865,7 @@ node=node->next; } - int season=xevent.Season(),episode=xevent.Episode(),episodeoverall; + int season=xevent.Season(),episode=xevent.Episode(),episodeoverall=0; char *epshorttext=NULL; char *eptitle=NULL; diff -Nru vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/xmltv2vdr.cpp vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/xmltv2vdr.cpp --- vdr-plugin-xmltv2vdr-0.2.0pre.git20140417/xmltv2vdr.cpp 2014-04-17 18:30:03.000000000 +0000 +++ vdr-plugin-xmltv2vdr-0.2.0pre.git20140810/xmltv2vdr.cpp 2014-08-10 11:41:23.000000000 +0000 @@ -747,9 +747,9 @@ if (xevent->Title() && Event->Title()) { - bool tChanged=false; if (strcasecmp(xevent->Title(),Event->Title())) { + bool tChanged=false; // Title maybe changed, check AltTitle if exists if (xevent->AltTitle()) {