tidy-up: replace (-1 != expressions

This commit is contained in:
Viktor Szakats 2025-07-09 19:05:57 +02:00
parent 8f18750bd2
commit 656c1cae6a
No known key found for this signature in database
GPG key ID: B5ABD165E2AEF201
4 changed files with 7 additions and 7 deletions

View file

@ -281,7 +281,7 @@ static CURLcode cw_download_write(struct Curl_easy *data,
* This gives deterministic BODY writes on varying buffer receive
* lengths. */
nwrite = nbytes;
if(-1 != data->req.maxdownload) {
if(data->req.maxdownload != -1) {
size_t wmax = get_max_body_write_len(data, data->req.maxdownload);
if(nwrite > wmax) {
excess_len = nbytes - wmax;
@ -879,7 +879,7 @@ static CURLcode cr_in_rewind(struct Curl_easy *data,
int err = fseek(data->state.in, 0, SEEK_SET);
CURL_TRC_READ(data, "cr_in, rewind via fseek -> %d(%d)",
(int)err, (int)errno);
if(-1 != err)
if(err != -1)
/* successful rewind */
return CURLE_OK;
}