diff options
author | Jan Kiszka <jan.kiszka@siemens.com> | 2011-01-21 18:19:40 +0100 |
---|---|---|
committer | Blue Swirl <blauwirbel@gmail.com> | 2011-01-21 17:32:45 +0000 |
commit | 789f88d0b21fedfd4251d56bb7a9fbfbda7a4ac7 (patch) | |
tree | b298f89336f527590de49548ebb1f579b2fc7fa7 | |
parent | b947c12c0bb217fe09968e652873e0d22b269d68 (diff) | |
download | hqemu-789f88d0b21fedfd4251d56bb7a9fbfbda7a4ac7.zip hqemu-789f88d0b21fedfd4251d56bb7a9fbfbda7a4ac7.tar.gz |
checkpatch: Fix bracing false positives on #else
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
-rwxr-xr-x | scripts/checkpatch.pl | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 55ef439..4fa06c0 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -2536,7 +2536,8 @@ sub process { } } if (!defined $suppress_ifbraces{$linenr - 1} && - $line =~ /\b(if|while|for|else)\b/) { + $line =~ /\b(if|while|for|else)\b/ && + $line !~ /\#\s*else/) { my $allowed = 0; # Check the pre-context. |