]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
checkpatch: ensure cast type is unique in the context parser
authorAndy Whitcroft <apw@canonical.com>
Fri, 2 Dec 2011 03:12:46 +0000 (14:12 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Mon, 5 Dec 2011 04:19:29 +0000 (15:19 +1100)
Ensure the cast type is unique in the context parser, we do not want them
to detect as a comma ','.

Signed-off-by: Andy Whitcroft <apw@canonical.com>
Cc: Joe Perches <joe@perches.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
scripts/checkpatch.pl

index ba7bcf34ad01e6bdf1b5f20371782c421ec7d717..497416c8360be6ee8381ad8864272d35e9d804da 100755 (executable)
@@ -1032,7 +1032,7 @@ sub annotate_values {
                } elsif ($cur =~ /^(\(\s*$Type\s*)\)/ && $av_pending eq '_') {
                        print "CAST($1)\n" if ($dbg_values > 1);
                        push(@av_paren_type, $type);
-                       $type = 'C';
+                       $type = 'c';
 
                } elsif ($cur =~ /^($Type)\s*(?:$Ident|,|\)|\(|\s*$)/) {
                        print "DECLARE($1)\n" if ($dbg_values > 1);