summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/core/wee-eval.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/core/wee-eval.c b/src/core/wee-eval.c
index 468e1497c..739db81e5 100644
--- a/src/core/wee-eval.c
+++ b/src/core/wee-eval.c
@@ -290,6 +290,8 @@ eval_replace_vars_cb (void *data, const char *text)
config_file_search_with_string (text, NULL, NULL, &ptr_option, NULL);
if (ptr_option)
{
+ if (!ptr_option->value)
+ return strdup ("");
switch (ptr_option->type)
{
case CONFIG_OPTION_TYPE_BOOLEAN:
@@ -305,7 +307,7 @@ eval_replace_vars_cb (void *data, const char *text)
case CONFIG_OPTION_TYPE_COLOR:
return strdup (gui_color_get_name (CONFIG_COLOR(ptr_option)));
case CONFIG_NUM_OPTION_TYPES:
- return NULL;
+ return strdup ("");
}
}
}