mirror of
https://gitlab.com/qemu-project/qemu
synced 2024-10-15 15:32:51 +00:00
checkpatch: Fix bracing false positives on #else
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
This commit is contained in:
parent
b947c12c0b
commit
789f88d0b2
|
@ -2536,7 +2536,8 @@ sub process {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!defined $suppress_ifbraces{$linenr - 1} &&
|
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;
|
my $allowed = 0;
|
||||||
|
|
||||||
# Check the pre-context.
|
# Check the pre-context.
|
||||||
|
|
Loading…
Reference in a new issue