diff options
-rwxr-xr-x | scripts/checkpatch.pl | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 7fb73d9..918259a 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -5105,8 +5105,8 @@ sub process { } # check for single line unbalanced braces - if ($sline =~ /.\s*\}\s*else\s*$/ || - $sline =~ /.\s*else\s*\{\s*$/) { + if ($sline =~ /^.\s*\}\s*else\s*$/ || + $sline =~ /^.\s*else\s*\{\s*$/) { CHK("BRACES", "Unbalanced braces around else statement\n" . $herecurr); } |