diff options
author | louis <louis.braun@gmx.de> | 2013-09-16 16:47:55 +0200 |
---|---|---|
committer | louis <louis.braun@gmx.de> | 2013-09-16 16:47:55 +0200 |
commit | 990d564ea04636430de588886a9a2f411cb625d5 (patch) | |
tree | caad079076f89d17e5d3291d609dff696f126e02 | |
parent | a12491ff265f0128939dbbbceae11461410c8a43 (diff) | |
download | vdr-plugin-tvscraper-990d564ea04636430de588886a9a2f411cb625d5.tar.gz vdr-plugin-tvscraper-990d564ea04636430de588886a9a2f411cb625d5.tar.bz2 |
Fixed a crash if internet connection is not available
-rw-r--r-- | HISTORY | 2 | ||||
-rw-r--r-- | worker.c | 8 |
2 files changed, 8 insertions, 2 deletions
@@ -37,3 +37,5 @@ Version 0.0.5 - introduced possibility to ignore titles, set scrap type and substitute search strings manually. See file "conf/override.conf" in source tree for explanation. +- Fixed a crash if a recording without EPG is running +- Fixed a crash if internet connection is not available @@ -97,6 +97,8 @@ bool cTVScraperWorker::ConnectScrapers(void) { moviedbScraper = new cMovieDBScraper(movieDir, db, language, overrides); if (!moviedbScraper->Connect()) { esyslog("tvscraper: ERROR, connection to TheMovieDB failed"); + delete moviedbScraper; + moviedbScraper = NULL; return false; } } @@ -104,6 +106,8 @@ bool cTVScraperWorker::ConnectScrapers(void) { tvdbScraper = new cTVDBScraper(seriesDir, db, language, overrides); if (!tvdbScraper->Connect()) { esyslog("tvscraper: ERROR, connection to TheTVDB failed"); + delete tvdbScraper; + tvdbScraper = NULL; return false; } } @@ -186,8 +190,8 @@ void cTVScraperWorker::CheckRunningTimers(void) { if (timer->Recording()) { const cEvent *event = timer->Event(); if (!event) - continue; - scrapType type = GetScrapType(event); + continue; + scrapType type = GetScrapType(event); if (type == scrapSeries) { if (!db->SetRecordingSeries((int)event->EventID())) { if (ConnectScrapers()) { |