mirror of
https://github.com/curl/curl.git
synced 2026-08-24 22:43:38 +03:00
urldata: remove crlf_conversions counter
Since the introduction of client writers, we check the body length in the PROTOCOL phase and do FTP lineend conversions laster in the CONTENT_DECODING phase. This means we no longer need to count the conversions for length checks. Closes #14709
This commit is contained in:
parent
1b0568539d
commit
64ab0ace27
4 changed files with 6 additions and 29 deletions
|
|
@ -518,15 +518,7 @@ CURLcode Curl_sendrecv(struct Curl_easy *data, struct curltime *nowp)
|
|||
* returning.
|
||||
*/
|
||||
if(!(data->req.no_body) && (k->size != -1) &&
|
||||
(k->bytecount != k->size) &&
|
||||
#ifdef CURL_DO_LINEEND_CONV
|
||||
/* Most FTP servers do not adjust their file SIZE response for CRLFs,
|
||||
so we will check to see if the discrepancy can be explained
|
||||
by the number of CRLFs we have changed to LFs.
|
||||
*/
|
||||
(k->bytecount != (k->size + data->state.crlf_conversions)) &&
|
||||
#endif /* CURL_DO_LINEEND_CONV */
|
||||
!k->newurl) {
|
||||
(k->bytecount != k->size) && !k->newurl) {
|
||||
failf(data, "transfer closed with %" CURL_FORMAT_CURL_OFF_T
|
||||
" bytes remaining to read", k->size - k->bytecount);
|
||||
result = CURLE_PARTIAL_FILE;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue