Browse code

Correct cast for snprintf

Andrew Alderwick authored on 07/01/2022 00:06:42
Showing 1 changed files
... ...
@@ -57,7 +57,7 @@ get_entry(char *p, Uint16 len, const char *pathname, const char *basename, int f
57 57
 	else if(S_ISDIR(st.st_mode))
58 58
 		return snprintf(p, len, "---- %s\n", basename);
59 59
 	else if(st.st_size < 0x10000)
60
-		return snprintf(p, len, "%04x %s\n", (Uint16)st.st_size, basename);
60
+		return snprintf(p, len, "%04x %s\n", (unsigned int)st.st_size, basename);
61 61
 	else
62 62
 		return snprintf(p, len, "???? %s\n", basename);
63 63
 }