]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
DVR: Fix regression - stop time, fixes #2834, fixes #2835
authorJaroslav Kysela <perex@perex.cz>
Sun, 10 May 2015 18:26:53 +0000 (20:26 +0200)
committerJaroslav Kysela <perex@perex.cz>
Sun, 10 May 2015 18:26:53 +0000 (20:26 +0200)
src/dvr/dvr_db.c

index 293c9161886d9dfc671124f0a520718bea59168b..d75dadbbb0b217474e089dbb03520ac877310f51 100644 (file)
@@ -894,13 +894,15 @@ static dvr_entry_t *_dvr_entry_update
   int save = 0;
 
   if (!dvr_entry_is_editable(de)) {
-    if (stop < dispatch_clock)
-      stop = dispatch_clock;
-    if (stop < de->de_start)
-      stop = de->de_start;
-    if (stop != de->de_stop) {
-      de->de_stop = stop;
-      save = 1;
+    if (stop > 0) {
+      if (stop < dispatch_clock)
+        stop = dispatch_clock;
+      if (stop < de->de_start)
+        stop = de->de_start;
+      if (stop != de->de_stop) {
+        de->de_stop = stop;
+        save = 1;
+      }
     }
     if (stop_extra && (stop_extra != de->de_stop_extra)) {
       de->de_stop_extra = stop_extra;