aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/slist_wc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/slist_wc.c b/src/slist_wc.c
index f4767ad84..d715bb21f 100644
--- a/src/slist_wc.c
+++ b/src/slist_wc.c
@@ -45,7 +45,7 @@ struct slist_wc *slist_wc_append(struct slist_wc *list,
list = malloc(sizeof(struct slist_wc));
if(!list) {
- free(new_item);
+ curl_slist_free_all(new_item);
return NULL;
}