Skip to content
Snippets Groups Projects
Commit 85313401 authored by Daniel Stenberg's avatar Daniel Stenberg
Browse files

minor leak in case of error, thanks to "./runtests.pl -n -t 25"

parent d3999e06
No related branches found
No related tags found
No related merge requests found
......@@ -1777,8 +1777,10 @@ CURLcode Curl_follow(struct SessionHandle *data,
newest=(char *)malloc( urllen + 1 + /* possible slash */
newlen + 1 /* zero byte */);
if(!newest)
if(!newest) {
free(url_clone); /* don't leak this */
return CURLE_OUT_OF_MEMORY; /* go out from this */
}
/* copy over the root url part */
memcpy(newest, url_clone, urllen);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment