tidy-up: replace (-1 == expressions examples

This commit is contained in:
Viktor Szakats 2025-07-09 19:45:24 +02:00
parent 571c57c508
commit b17c0a2b4f
No known key found for this signature in database
GPG key ID: B5ABD165E2AEF201
2 changed files with 2 additions and 2 deletions

View file

@ -61,7 +61,7 @@ static int my_seek(void *userp, curl_off_t offset, int origin)
{
FILE *fp = (FILE *) userp;
if(-1 == fseek(fp, (long) offset, origin))
if(fseek(fp, (long) offset, origin) == -1)
/* could not seek */
return CURL_SEEKFUNC_CANTSEEK;

View file

@ -83,7 +83,7 @@ static int sftpResumeUpload(CURL *curlhandle, const char *remotepath,
CURLcode result = CURLE_GOT_NOTHING;
curl_off_t remoteFileSizeByte = sftpGetRemoteFileSize(remotepath);
if(-1 == remoteFileSizeByte) {
if(remoteFileSizeByte == -1) {
printf("Error reading the remote file size: unable to resume upload\n");
return -1;
}