]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
unit1664: drop casts, expand masks to full values
authorViktor Szakats <commit@vsz.me>
Sat, 4 Oct 2025 00:53:02 +0000 (02:53 +0200)
committerViktor Szakats <commit@vsz.me>
Sat, 4 Oct 2025 15:49:21 +0000 (17:49 +0200)
Follow-up to 4deea9396bc7dd25c6362fa746a57bf309c74ada #18814

Closes #18838

tests/unit/unit1664.c

index 773bd8d386cce98786900702c4f78876e395d958..6903c70e92988b44e18f4e1b02b9c95065e7a6cf 100644 (file)
@@ -193,8 +193,8 @@ static CURLcode test_unit1664(const char *arg)
       const char *line = nums[i];
       const char *orgline = line;
       int rc = curlx_str_number(&line, &num, 1235);
-      curl_mprintf("%u: (\"%s\") %d, [%u] line %d\n",
-                   i, orgline, rc, (int)num, (int)(line - orgline));
+      curl_mprintf("%u: (\"%s\") %d, [%" CURL_FORMAT_CURL_OFF_T "] line %d\n",
+                   i, orgline, rc, num, (int)(line - orgline));
     }
   }
 
@@ -388,8 +388,8 @@ static CURLcode test_unit1664(const char *arg)
       const char *line = nums[i];
       const char *orgline = line;
       int rc = curlx_str_hex(&line, &num, 0x1235);
-      curl_mprintf("%u: (\"%s\") %d, [%u] line %d\n",
-                   i, orgline, rc, (int)num, (int)(line - orgline));
+      curl_mprintf("%u: (\"%s\") %d, [%" CURL_FORMAT_CURL_OFF_T "] line %d\n",
+                   i, orgline, rc, num, (int)(line - orgline));
     }
   }
 
@@ -415,8 +415,8 @@ static CURLcode test_unit1664(const char *arg)
       const char *line = nums[i];
       const char *orgline = line;
       int rc = curlx_str_octal(&line, &num, 01235);
-      curl_mprintf("%u: (\"%s\") %d, [%u] line %d\n",
-                   i, orgline, rc, (int)num, (int)(line - orgline));
+      curl_mprintf("%u: (\"%s\") %d, [%" CURL_FORMAT_CURL_OFF_T "] line %d\n",
+                   i, orgline, rc, num, (int)(line - orgline));
     }
   }