mirror of
https://github.com/curl/curl.git
synced 2026-08-25 01:43: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
|
|
@ -1050,7 +1050,7 @@ static CURLcode smtp_state_command_resp(struct Curl_easy *data, int smtpcode,
|
|||
}
|
||||
else {
|
||||
/* Temporarily add the LF character back and send as body to the client */
|
||||
if(!data->set.opt_no_body) {
|
||||
if(!data->req.no_body) {
|
||||
line[len] = '\n';
|
||||
result = Curl_client_write(data, CLIENTWRITE_BODY, line, len + 1);
|
||||
line[len] = '\0';
|
||||
|
|
@ -1490,7 +1490,7 @@ static CURLcode smtp_perform(struct Curl_easy *data, bool *connected,
|
|||
|
||||
DEBUGF(infof(data, "DO phase starts"));
|
||||
|
||||
if(data->set.opt_no_body) {
|
||||
if(data->req.no_body) {
|
||||
/* Requested no body means no transfer */
|
||||
smtp->transfer = PPTRANSFER_INFO;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue