From: Yang Tse Date: Mon, 29 Jul 2013 16:23:38 +0000 (+0200) Subject: tool_operhlp.c: fix add_file_name_to_url() OOM handling X-Git-Tag: curl-7_32_0~48 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9a5c2d83734ec671f7fb81788a916f9ffa6fb4b6;p=curl tool_operhlp.c: fix add_file_name_to_url() OOM handling --- diff --git a/src/tool_operhlp.c b/src/tool_operhlp.c index d3c1a88a9..c33ca507d 100644 --- a/src/tool_operhlp.c +++ b/src/tool_operhlp.c @@ -139,6 +139,8 @@ char *add_file_name_to_url(CURL *curl, char *url, const char *filename) url = urlbuffer; /* use our new URL instead! */ } + else + Curl_safefree(url); } return url; }