From b668e52c906b664b353d5a99cfa3ff36f73b341d Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Sun, 15 Feb 2026 14:41:20 +0100 Subject: *: placate warnings where strchr/strstr returns constant pointer Newer glibc is now smarter and can propagate const-ness from those! function old new delta readtoken1 3111 3108 -3 Signed-off-by: Denys Vlasenko --- coreutils/printf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'coreutils/printf.c') diff --git a/coreutils/printf.c b/coreutils/printf.c index 4edcfa9b5..3cd48cfcc 100644 --- a/coreutils/printf.c +++ b/coreutils/printf.c @@ -354,7 +354,7 @@ static char **print_formatted(char *f, char **argv, int *conv_err) /* Add "ll" if integer modifier, then print */ { static const char format_chars[] ALIGN1 = "diouxXfeEgGcs"; - char *p = strchr(format_chars, *f); + char *p = (char*)strchr(format_chars, *f); /* needed - try "printf %" without it */ if (p == NULL || *f == '\0') { bb_error_msg("%s: invalid format", direc_start); -- cgit v1.2.3-55-g6feb