]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
DVR: fix for 'handle SM_CODE_USER_REQUEST as a successful case', fixes #4609
authorJaroslav Kysela <perex@perex.cz>
Tue, 19 Sep 2017 06:24:37 +0000 (08:24 +0200)
committerJaroslav Kysela <perex@perex.cz>
Tue, 19 Sep 2017 06:29:07 +0000 (08:29 +0200)
src/dvr/dvr_db.c

index 0525ff9b355bb9f73896391165d706a06cba014d..f9b854a455fa7715133967643626b8f8c258faa9 100644 (file)
@@ -145,7 +145,7 @@ int dvr_entry_is_finished(dvr_entry_t *entry, int flags)
   int success = entry->de_sched_state == DVR_COMPLETED;
 
   if (success && entry->de_last_error != SM_CODE_USER_REQUEST)
-      success = entry->de_last_error != SM_CODE_OK &&
+      success = entry->de_last_error == SM_CODE_OK &&
                 entry->de_data_errors < DVR_MAX_DATA_ERRORS;
 
   if ((flags & DVR_FINISHED_REMOVED_SUCCESS) && removed && success)