]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
ctrlaltdel: pass correct integer types to printf
authorThomas Weißschuh <thomas@t-8ch.de>
Wed, 22 Apr 2026 21:40:51 +0000 (23:40 +0200)
committerThomas Weißschuh <thomas@t-8ch.de>
Thu, 14 May 2026 11:19:43 +0000 (13:19 +0200)
The printf format %ju expects an 'uintmax_t'. Cast the value to make
sure the correct type is passed.

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
sys-utils/ctrlaltdel.c

index 1601154f858f7f3a5c3f67d1d4fe5f526c03789b..54179c849584cd091c31e060109b1631eaef0048 100644 (file)
@@ -58,7 +58,7 @@ static int get_cad(void)
                break;
        default:
                printf("%s hard\n", _("implicit"));
-               warnx(_("unexpected value in %s: %ju"), _PATH_PROC_CTRL_ALT_DEL, val);
+               warnx(_("unexpected value in %s: %ju"), _PATH_PROC_CTRL_ALT_DEL, (uintmax_t)val);
                return EXIT_FAILURE;
        }
        return EXIT_SUCCESS;