summaryrefslogtreecommitdiff
path: root/options.c
diff options
context:
space:
mode:
Diffstat (limited to 'options.c')
-rw-r--r--options.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/options.c b/options.c
index d14c287..6f08a0f 100644
--- a/options.c
+++ b/options.c
@@ -690,8 +690,10 @@ char * paramvalues_to_string(option_t *opt, char **paramvalues)
dstr_t *res = create_dstr();
char *data;
- if (opt->param_count < 1)
+ if (opt->param_count < 1) {
+ free (res);
return NULL;
+ }
if (opt->param_count == 1) {
param = opt->paramlist;