tools: we specifically added %Lu to our sprintfrr so allow it

Signed-off-by: Christian Hopps <chopps@labn.net>
This commit is contained in:
Christian Hopps 2025-01-07 01:34:13 -05:00
parent 9aa2b04874
commit bdfb6a3db7

View file

@ -6285,13 +6285,14 @@ sub process {
while ($line =~ /(?:^|")([X\t]*)(?:"|$)/g) { while ($line =~ /(?:^|")([X\t]*)(?:"|$)/g) {
my $string = substr($rawline, $-[1], $+[1] - $-[1]); my $string = substr($rawline, $-[1], $+[1] - $-[1]);
$string =~ s/%%/__/g; $string =~ s/%%/__/g;
# check for %L # check for %L
if ($show_L && $string =~ /%[\*\d\.\$]*L([diouxX])/) { # OK in FRR
WARN("PRINTF_L", # if ($show_L && $string =~ /%[\*\d\.\$]*L([diouxX])/) {
"\%L$1 is non-standard C, use %ll$1\n" . $herecurr); # WARN("PRINTF_L",
$show_L = 0; # "\%L$1 is non-standard C, use %ll$1\n" . $herecurr);
} # $show_L = 0;
# check for %Z # }
# check for %Z
if ($show_Z && $string =~ /%[\*\d\.\$]*Z([diouxX])/) { if ($show_Z && $string =~ /%[\*\d\.\$]*Z([diouxX])/) {
WARN("PRINTF_Z", WARN("PRINTF_Z",
"%Z$1 is non-standard C, use %z$1\n" . $herecurr); "%Z$1 is non-standard C, use %z$1\n" . $herecurr);