lib/commonio.c: Use uintmax_t to print nlink_t

See uintmax_t(3type).

While at it, remove the useless cast to (void).

Signed-off-by: Alejandro Colomar <alx@kernel.org>
This commit is contained in:
Alejandro Colomar
2023-09-02 14:29:07 +02:00
committed by Iker Pedrosa
parent 6be85b0baf
commit 97e9d60133
+3 -3
View File
@@ -110,9 +110,9 @@ static int check_link_count (const char *file, bool log)
if (sb.st_nlink != 2) {
if (log) {
(void) fprintf (shadow_logfd,
"%s: %s: lock file already used (nlink: %u)\n",
shadow_progname, file, sb.st_nlink);
fprintf(shadow_logfd,
"%s: %s: lock file already used (nlink: %ju)\n",
shadow_progname, file, (uintmax_t) sb.st_nlink);
}
return 0;
}