audio.out.dither_method = hb_value_get_int(dither);
}
}
- audio.out.name = name;
+ if (name != NULL)
+ {
+ audio.out.name = strdup(name);
+ }
if (audio.in.track >= 0)
{
audio.out.track = ii;
if (subtitle != NULL)
{
sub_config = subtitle->config;
- sub_config.name = name;
+ if (name != NULL)
+ {
+ sub_config.name = strdup(name);
+ }
result = json_unpack_ex(subtitle_dict, &error, 0,
"{s?b, s?b, s?b, s?I}",
"Default", unpack_b(&sub_config.default_track),
}
else if (importfile != NULL)
{
- sub_config.src_filename = importfile;
+ sub_config.src_filename = strdup(importfile);
const char * lang = "und";
const char * srtcodeset = "UTF-8";
hb_job_close(&job);
return NULL;
}
- sub_config.name = name;
+ if (name != NULL)
+ {
+ sub_config.name = strdup(name);
+ }
sub_config.offset = offset;
sub_config.dest = burn ? RENDERSUB : PASSTHRUSUB;
strncpy(sub_config.src_codeset, srtcodeset, 39);