From: Adam Sutton Date: Wed, 20 Feb 2013 11:18:30 +0000 (+0000) Subject: timeshift: fix NULL ptr issue X-Git-Tag: 3.4beta1~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=899773ee6078448f0bf049e7befd52e22732eee2;p=thirdparty%2Ftvheadend.git timeshift: fix NULL ptr issue (cherry picked from commit 06f83663c1f8203c2b22be1f6df1dc58a9524cc1) --- diff --git a/src/timeshift/timeshift_filemgr.c b/src/timeshift/timeshift_filemgr.c index 5ce488e07..56a4c2cd3 100644 --- a/src/timeshift/timeshift_filemgr.c +++ b/src/timeshift/timeshift_filemgr.c @@ -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; }