mirror of
https://github.com/curl/curl.git
synced 2026-08-25 08:23:31 +03:00
lib: rename curlx_timediff to curlx_timeleft_ms
Rename `Curl_timeleft()` to `Curl_timeleft_ms()` to make the units in the returned `timediff_t` clear. (We used to always have ms there, but with QUIC started to sometimes calc ns as well). Rename some assigned vars without `_ms` suffix for clarity as well. Closes #19486
This commit is contained in:
parent
ca27404d27
commit
78a610cb83
53 changed files with 187 additions and 188 deletions
|
|
@ -422,18 +422,18 @@ CURLcode Curl_sendrecv(struct Curl_easy *data, struct curltime *nowp)
|
|||
goto out;
|
||||
|
||||
if(k->keepon) {
|
||||
if(0 > Curl_timeleft(data, nowp, FALSE)) {
|
||||
if(Curl_timeleft_ms(data, nowp, FALSE) < 0) {
|
||||
if(k->size != -1) {
|
||||
failf(data, "Operation timed out after %" FMT_TIMEDIFF_T
|
||||
" milliseconds with %" FMT_OFF_T " out of %"
|
||||
FMT_OFF_T " bytes received",
|
||||
curlx_timediff(*nowp, data->progress.t_startsingle),
|
||||
curlx_timediff_ms(*nowp, data->progress.t_startsingle),
|
||||
k->bytecount, k->size);
|
||||
}
|
||||
else {
|
||||
failf(data, "Operation timed out after %" FMT_TIMEDIFF_T
|
||||
" milliseconds with %" FMT_OFF_T " bytes received",
|
||||
curlx_timediff(*nowp, data->progress.t_startsingle),
|
||||
curlx_timediff_ms(*nowp, data->progress.t_startsingle),
|
||||
k->bytecount);
|
||||
}
|
||||
result = CURLE_OPERATION_TIMEDOUT;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue