]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
DVR: fix '', fixes #4904
authorJaroslav Kysela <perex@perex.cz>
Sat, 3 Feb 2018 12:21:56 +0000 (13:21 +0100)
committerJaroslav Kysela <perex@perex.cz>
Sat, 3 Feb 2018 12:21:56 +0000 (13:21 +0100)
src/dvr/dvr_rec.c

index 903a661ce4251aa60806885e8f671b6ca3772a0d..9cb7a91cdcb33f4a0f97d207130bad91596da3e9 100644 (file)
@@ -413,7 +413,7 @@ _dvr_sub_scraper_friendly(const char *id, const char *fmt, const void *aux, char
 
   const size_t title_buf_size = title ? strlen(title) + 1 : 0;
   char *title_buf = title ? alloca(title_buf_size) : NULL;
-  const size_t subtitle_buf_size = title ? strlen(title) + 1 : 0;
+  const size_t subtitle_buf_size = subtitle ? strlen(subtitle) + 1 : 0;
   char *subtitle_buf = subtitle ? alloca(subtitle_buf_size) : NULL;
   /* Copy a cleaned version in to our buffers.
    * Since dvr_clean_directory_separator _can_ modify source if source!=dest