core: check that option is not NULL in function config_file_option_value_to_string

This commit is contained in:
Sébastien Helleu 2021-09-27 23:23:01 +02:00
parent 301f0942c6
commit 9548a4cf74

View File

@ -1748,6 +1748,9 @@ config_file_option_value_to_string (struct t_config_option *option,
const char *ptr_value;
int enabled, length;
if (!option)
return NULL;
if ((default_value && !option->default_value)
|| (!default_value && !option->value))
{