]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
Update timeshift_filemgr.c
authorJ. Dierkse <j.dierkse@madeo.nl>
Wed, 14 Jan 2015 20:49:52 +0000 (21:49 +0100)
committerJaroslav Kysela <perex@perex.cz>
Thu, 15 Jan 2015 13:18:03 +0000 (14:18 +0100)
It seems that in currently the timeshift_unlimited_period boolean is completely ignored when it comes to taking action on removing files or reporting a full buffer. This small patch should fix that, so that when the timeshift_unlimited_period boolean is set to true, tvheadend no longer evaluates the period of the current timeshift.

src/timeshift/timeshift_filemgr.c

index a95953c67ba638c7354e45230cfa8965e10d7e3c..2cf8e00ca7aea7115af48278d445120657c91b98 100644 (file)
@@ -208,7 +208,8 @@ timeshift_file_t *timeshift_filemgr_get ( timeshift_t *ts, int create )
       timeshift_filemgr_close(tsf_tl);
 
     /* Check period */
-    if (ts->max_time && tsf_hd && tsf_tl) {
+    if (!timeshift_unlimited_period &&
+        ts->max_time && tsf_hd && tsf_tl) {
       time_t d = (tsf_tl->time - tsf_hd->time) * TIMESHIFT_FILE_PERIOD;
       if (d > (ts->max_time+5)) {
         if (!tsf_hd->refcount) {