mirror of
https://github.com/moparisthebest/curl
synced 2024-12-21 23:58:49 -05:00
progress: reset flags at transfer start
When an easy handle is used to download an URI which has no Content-Length header (or equivalent) after downloading an URI which does, the value from the previous transfer is reused and returned by CURLINFO_CONTENT_LENGTH_DOWNLOAD. This is because the progress flags (used to determine whether such a header was received) are not reset between transfers. Bug: http://curl.haxx.se/bug/view.cgi?id=3370895
This commit is contained in:
parent
dcc8481a13
commit
27b8814017
@ -201,6 +201,7 @@ void Curl_pgrsStartNow(struct SessionHandle *data)
|
||||
{
|
||||
data->progress.speeder_c = 0; /* reset the progress meter display */
|
||||
data->progress.start = Curl_tvnow();
|
||||
data->progress.flags = 0;
|
||||
}
|
||||
|
||||
void Curl_pgrsSetDownloadCounter(struct SessionHandle *data, curl_off_t size)
|
||||
|
Loading…
Reference in New Issue
Block a user