]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
DVR: filename builder, do not crash when title/subtitle is not defined, fixes #2883
authorJaroslav Kysela <perex@perex.cz>
Mon, 25 May 2015 06:56:58 +0000 (08:56 +0200)
committerJaroslav Kysela <perex@perex.cz>
Mon, 25 May 2015 06:56:58 +0000 (08:56 +0200)
src/dvr/dvr_rec.c

index 3789a25f8c6837b0ca5265d026deda11f933a3dd..c72e638107857a8ae950a6e05f957579720c45dc 100644 (file)
@@ -223,12 +223,12 @@ cleanup_filename(dvr_config_t *cfg, char *s)
 
 static const char *dvr_sub_title(const char *id, const void *aux)
 {
-  return lang_str_get(((dvr_entry_t *)aux)->de_title, NULL);
+  return lang_str_get(((dvr_entry_t *)aux)->de_title, NULL) ?: "";
 }
 
 static const char *dvr_sub_subtitle(const char *id, const void *aux)
 {
-  return lang_str_get(((dvr_entry_t *)aux)->de_subtitle, NULL);
+  return lang_str_get(((dvr_entry_t *)aux)->de_subtitle, NULL) ?: "";
 }
 
 static const char *dvr_sub_episode(const char *id, const void *aux)