]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
DVR - Bugfix - Duplicate recordings 18/head
authorton.van.der.poel <ton.van.der.poel@ubuntu.(none)>
Wed, 23 Feb 2011 20:42:57 +0000 (21:42 +0100)
committerton.van.der.poel <ton.van.der.poel@ubuntu.(none)>
Wed, 23 Feb 2011 20:42:57 +0000 (21:42 +0100)
In some situations (I suspend my main pvr machine, and use a script to wake it up before
recordings, this means I stop and start tvheadend multiple times a day), tvheadend starts
parsing EPG-data agains AutoRec rules before previously scheduled recordings are loaded
from disk.

Since the check for duplicate recordings is not present in the code that loads previously
scheduled recordings from disk, it would mean that when an autorec-rule was triggered, this
would result in duplicate scheduled recordings.

By first restoring previously scheduled recordings from disk and then loading the AutoRec
rules, this situation can not happen anymore...

src/dvr/dvr_db.c

index 365d8f14698da6a023e59babd050f2601564d335..aa59112f0df31c08c5e0a693cc6391f7f0cd4739 100644 (file)
@@ -834,9 +834,9 @@ dvr_init(void)
     }
   }
 
-  dvr_autorec_init();
-
   dvr_db_load();
+
+  dvr_autorec_init();
 }
 
 /**