]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
timeshift: fix NULL ptr issue
authorAdam Sutton <dev@adamsutton.me.uk>
Wed, 20 Feb 2013 11:18:30 +0000 (11:18 +0000)
committerAdam Sutton <dev@adamsutton.me.uk>
Thu, 21 Feb 2013 16:00:01 +0000 (16:00 +0000)
(cherry picked from commit 06f83663c1f8203c2b22be1f6df1dc58a9524cc1)

src/timeshift/timeshift_filemgr.c

index 5ce488e07a6cab2c8eec1778be4980073646f591..56a4c2cd3589d3e2fb657ee14beda49984a8aac1 100644 (file)
@@ -281,7 +281,8 @@ timeshift_file_t *timeshift_filemgr_get ( timeshift_t *ts, int create )
     tsf_tl = tsf_tmp;
   }
 
-  tsf_tl->refcount++;
+  if (tsf_tl)
+    tsf_tl->refcount++;
   return tsf_tl;
 }