mirror of
https://github.com/curl/curl.git
synced 2026-08-26 03:53:32 +03:00
lib: remove bad set.opt_no_body assignments
This struct field MUST remain what the application set it to, so that handle reuse and handle duplication work. Instead, the request state bit 'no_body' is introduced for code flows that need to change this in run-time. Closes #9888
This commit is contained in:
parent
dafdb20a26
commit
bf12c2bed6
13 changed files with 30 additions and 28 deletions
|
|
@ -482,13 +482,13 @@ static CURLcode file_do(struct Curl_easy *data, bool *done)
|
|||
tm->tm_hour,
|
||||
tm->tm_min,
|
||||
tm->tm_sec,
|
||||
data->set.opt_no_body ? "": "\r\n");
|
||||
data->req.no_body ? "": "\r\n");
|
||||
result = Curl_client_write(data, CLIENTWRITE_HEADER, header, headerlen);
|
||||
if(result)
|
||||
return result;
|
||||
/* set the file size to make it available post transfer */
|
||||
Curl_pgrsSetDownloadSize(data, expected_size);
|
||||
if(data->set.opt_no_body)
|
||||
if(data->req.no_body)
|
||||
return result;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue