Skip to content

Commit

Permalink
tools: we specifically added %Lu to our sprintfrr so allow it
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Hopps <chopps@labn.net>
  • Loading branch information
choppsv1 committed Jan 7, 2025
1 parent 9aa2b04 commit bdfb6a3
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions tools/checkpatch.pl
Original file line number Diff line number Diff line change
Expand Up @@ -6285,13 +6285,14 @@ sub process {
while ($line =~ /(?:^|")([X\t]*)(?:"|$)/g) {
my $string = substr($rawline, $-[1], $+[1] - $-[1]);
$string =~ s/%%/__/g;
# check for %L
if ($show_L && $string =~ /%[\*\d\.\$]*L([diouxX])/) {
WARN("PRINTF_L",
"\%L$1 is non-standard C, use %ll$1\n" . $herecurr);
$show_L = 0;
}
# check for %Z
# check for %L
# OK in FRR
# if ($show_L && $string =~ /%[\*\d\.\$]*L([diouxX])/) {
# WARN("PRINTF_L",
# "\%L$1 is non-standard C, use %ll$1\n" . $herecurr);
# $show_L = 0;
# }
# check for %Z
if ($show_Z && $string =~ /%[\*\d\.\$]*Z([diouxX])/) {
WARN("PRINTF_Z",
"%Z$1 is non-standard C, use %z$1\n" . $herecurr);
Expand Down

0 comments on commit bdfb6a3

Please sign in to comment.