mirror of
https://github.com/curl/curl.git
synced 2026-07-23 00:27:24 +03:00
http: mark POSTs with no body as "upload done" from the start
As we have logic that checks if we get a >= 400 reponse code back before the upload is done, which then got confused since it wasn't "done" but yet there was no data to send! Reported-by: IvanoG on github Fixes #4996 Closes #5002
This commit is contained in:
parent
5494afac8f
commit
0caae3c4be
1 changed files with 2 additions and 0 deletions
|
|
@ -3044,6 +3044,8 @@ CURLcode Curl_http(struct connectdata *conn, bool *done)
|
|||
}
|
||||
if(result)
|
||||
return result;
|
||||
if(!postsize)
|
||||
data->req.upload_done = TRUE;
|
||||
|
||||
if(data->req.writebytecount) {
|
||||
/* if a request-body has been sent off, we make sure this progress is noted
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue