summaryrefslogtreecommitdiff
path: root/libs/libcurl/src/sendf.c
diff options
context:
space:
mode:
authordartraiden <wowemuh@gmail.com>2024-09-11 21:49:43 +0300
committerdartraiden <wowemuh@gmail.com>2024-09-11 21:52:35 +0300
commitc36db68a5f58ec6c9135eff778b6e77c30e58088 (patch)
tree22eea126db82c50388c9f94cd683d6ec6f04e6cb /libs/libcurl/src/sendf.c
parent02bb82c1c0a4031e7b2f5578370fa5acd620f8e1 (diff)
libcurl: update to 8.10.0
Diffstat (limited to 'libs/libcurl/src/sendf.c')
-rw-r--r--libs/libcurl/src/sendf.c35
1 files changed, 15 insertions, 20 deletions
diff --git a/libs/libcurl/src/sendf.c b/libs/libcurl/src/sendf.c
index 390907fae8..92b21dc7ea 100644
--- a/libs/libcurl/src/sendf.c
+++ b/libs/libcurl/src/sendf.c
@@ -292,8 +292,8 @@ static CURLcode cw_download_write(struct Curl_easy *data,
if((type & CLIENTWRITE_EOS) && !data->req.no_body &&
(data->req.maxdownload > data->req.bytecount)) {
- failf(data, "end of response with %" CURL_FORMAT_CURL_OFF_T
- " bytes missing", data->req.maxdownload - data->req.bytecount);
+ failf(data, "end of response with %" FMT_OFF_T " bytes missing",
+ data->req.maxdownload - data->req.bytecount);
return CURLE_PARTIAL_FILE;
}
}
@@ -328,9 +328,9 @@ static CURLcode cw_download_write(struct Curl_easy *data,
infof(data,
"Excess found writing body:"
" excess = %zu"
- ", size = %" CURL_FORMAT_CURL_OFF_T
- ", maxdownload = %" CURL_FORMAT_CURL_OFF_T
- ", bytecount = %" CURL_FORMAT_CURL_OFF_T,
+ ", size = %" FMT_OFF_T
+ ", maxdownload = %" FMT_OFF_T
+ ", bytecount = %" FMT_OFF_T,
excess_len, data->req.size, data->req.maxdownload,
data->req.bytecount);
connclose(data->conn, "excess found in a read");
@@ -338,8 +338,7 @@ static CURLcode cw_download_write(struct Curl_easy *data,
}
else if(nwrite < nbytes) {
failf(data, "Exceeded the maximum allowed file size "
- "(%" CURL_FORMAT_CURL_OFF_T ") with %"
- CURL_FORMAT_CURL_OFF_T " bytes",
+ "(%" FMT_OFF_T ") with %" FMT_OFF_T " bytes",
data->set.max_filesize, data->req.bytecount);
return CURLE_FILESIZE_EXCEEDED;
}
@@ -688,8 +687,8 @@ static CURLcode cr_in_read(struct Curl_easy *data,
case 0:
if((ctx->total_len >= 0) && (ctx->read_len < ctx->total_len)) {
failf(data, "client read function EOF fail, "
- "only %"CURL_FORMAT_CURL_OFF_T"/%"CURL_FORMAT_CURL_OFF_T
- " of needed bytes read", ctx->read_len, ctx->total_len);
+ "only %"FMT_OFF_T"/%"FMT_OFF_T " of needed bytes read",
+ ctx->read_len, ctx->total_len);
return CURLE_READ_ERROR;
}
*pnread = 0;
@@ -738,8 +737,8 @@ static CURLcode cr_in_read(struct Curl_easy *data,
*peos = ctx->seen_eos;
break;
}
- CURL_TRC_READ(data, "cr_in_read(len=%zu, total=%"CURL_FORMAT_CURL_OFF_T
- ", read=%"CURL_FORMAT_CURL_OFF_T") -> %d, nread=%zu, eos=%d",
+ CURL_TRC_READ(data, "cr_in_read(len=%zu, total=%"FMT_OFF_T
+ ", read=%"FMT_OFF_T") -> %d, nread=%zu, eos=%d",
blen, ctx->total_len, ctx->read_len, CURLE_OK,
*pnread, *peos);
return CURLE_OK;
@@ -804,8 +803,8 @@ static CURLcode cr_in_resume_from(struct Curl_easy *data,
if((actuallyread == 0) || (actuallyread > readthisamountnow)) {
/* this checks for greater-than only to make sure that the
CURL_READFUNC_ABORT return code still aborts */
- failf(data, "Could only read %" CURL_FORMAT_CURL_OFF_T
- " bytes from the input", passed);
+ failf(data, "Could only read %" FMT_OFF_T " bytes from the input",
+ passed);
return CURLE_READ_ERROR;
}
} while(passed < offset);
@@ -1102,11 +1101,7 @@ static CURLcode do_init_reader_stack(struct Curl_easy *data,
clen = r->crt->total_length(data, r);
/* if we do not have 0 length init, and crlf conversion is wanted,
* add the reader for it */
- if(clen && (data->set.crlf
-#ifdef CURL_DO_LINEEND_CONV
- || data->state.prefer_ascii
-#endif
- )) {
+ if(clen && (data->set.crlf || data->state.prefer_ascii)) {
result = cr_lc_add(data);
if(result)
return result;
@@ -1130,8 +1125,8 @@ CURLcode Curl_creader_set_fread(struct Curl_easy *data, curl_off_t len)
cl_reset_reader(data);
result = do_init_reader_stack(data, r);
out:
- CURL_TRC_READ(data, "add fread reader, len=%"CURL_FORMAT_CURL_OFF_T
- " -> %d", len, result);
+ CURL_TRC_READ(data, "add fread reader, len=%"FMT_OFF_T " -> %d",
+ len, result);
return result;
}