mirror of
https://github.com/curl/curl.git
synced 2026-05-16 00:36:21 +03:00
Ingo Wilken's redirect fixes
This commit is contained in:
parent
dc6da007ad
commit
fef1fc0d32
2 changed files with 7 additions and 0 deletions
|
|
@ -910,6 +910,7 @@ CURLcode Curl_perform(CURL *curl)
|
|||
|
||||
/* TBD: set the URL with curl_setopt() */
|
||||
data->url = newurl;
|
||||
newurl = NULL; /* don't free! */
|
||||
|
||||
data->bits.urlstringalloc = TRUE; /* the URL is allocated */
|
||||
|
||||
|
|
|
|||
|
|
@ -2233,6 +2233,12 @@ CURLcode Curl_done(struct connectdata *conn)
|
|||
conn->bits.rangestringalloc = FALSE;
|
||||
}
|
||||
|
||||
/* Cleanup possible redirect junk */
|
||||
if(conn->newurl) {
|
||||
free(conn->newurl);
|
||||
conn->newurl = NULL;
|
||||
}
|
||||
|
||||
/* this calls the protocol-specific function pointer previously set */
|
||||
if(conn->curl_done)
|
||||
result = conn->curl_done(conn);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue