From: Pierrick Charron Date: Mon, 5 Dec 2011 22:23:19 +0000 (+0000) Subject: We should free the memory of any curl_slist returned by curl_easy_getinfo X-Git-Tag: php-5.5.0alpha1~770 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e038f2fe5d511d7c627f3dd0f4b80aeb1e6e87d0;p=php We should free the memory of any curl_slist returned by curl_easy_getinfo --- diff --git a/ext/curl/interface.c b/ext/curl/interface.c index 6eb1fa94c2..c9a80ed2e1 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -3031,6 +3031,7 @@ PHP_FUNCTION(curl_getinfo) add_next_index_string(return_value, slist->data, 1); slist = slist->next; } + curl_slist_free_all(slist); } else { RETURN_FALSE; }