diff options
author | Daniel Stenberg <daniel@haxx.se> | 2014-05-24 19:05:12 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2014-05-24 19:06:11 +0200 |
commit | ac6da721a3740500cc0764947385eb1c22116b83 (patch) | |
tree | 220b8b3c92705c6692f4faf6c8bed4988c6b0be2 | |
parent | b3d0e4e24385c88857463c7ecd6693fbb7a54d37 (diff) |
curl_easy_reset: reset the URL
Make sure that the URL is reset and cleared.
Bug: http://curl.haxx.se/mail/lib-2014-05/0235.html
Reported-by: Jonathan Cardoso Machado
-rw-r--r-- | lib/url.c | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -278,6 +278,11 @@ void Curl_freeset(struct SessionHandle *data) data->change.referer_alloc = FALSE; } data->change.referer = NULL; + if(data->change.url_alloc) { + Curl_safefree(data->change.url); + data->change.url_alloc = FALSE; + } + data->change.url = NULL; } static CURLcode setstropt(char **charp, char *s) |