mirror of
https://github.com/curl/curl.git
synced 2026-07-25 02:47:17 +03:00
now counts header size return from server and if nothing is returned from a
HTTP server we return error
This commit is contained in:
parent
74d5a6fb3b
commit
4e37187e44
4 changed files with 13 additions and 2 deletions
|
|
@ -352,6 +352,13 @@ CURLcode Curl_http_done(struct connectdata *conn)
|
|||
*bytecount = http->readbytecount + http->writebytecount;
|
||||
}
|
||||
|
||||
if(0 == (http->readbytecount + conn->headerbytecount)) {
|
||||
/* nothing was read from the HTTP server, this can't be right
|
||||
so we return an error here */
|
||||
failf(data, "Empty reply from server\n");
|
||||
return CURLE_GOT_NOTHING;
|
||||
}
|
||||
|
||||
return CURLE_OK;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue