History

checkpatch: pointer type star may have modifiers following

We may have any modifier following a pointer type star. Handle this: void * __user * __user foo;

Andy Whitcroft committed 17 years ago

Commit a3340b31 parent 00ef4ec1 file · +2 −2Browse files

Showing the changes to scripts/checkpatch.pl (1 of 1 file). Show all

Unified · Split

scripts/checkpatch.pl+2−2
@@ -1886,11 +1886,11 @@ sub process { · 1885 unmodified lines
18861886 if ($ctx !~ /[WEBC]x./ && $ca !~ /(?:\)|!|~|\*|-|\&|\||\+\+|\-\-|\{)$/) {
18871887 ERROR("space required before that '$op' $at\n" . $hereptr);
18881888 }
1889− if ($op eq '*' && $cc =~/\s*const\b/) {
1889+ if ($op eq '*' && $cc =~/\s*$Modifier\b/) {
18901890 # A unary '*' may be const
18911891
18921892 } elsif ($ctx =~ /.xW/) {
1893− ERROR("space prohibited after that '$op' $at\n" . $hereptr);
1893+ ERROR("Aspace prohibited after that '$op' $at\n" . $hereptr);
18941894 }
18951895
18961896 # unary ++ and unary -- are allowed no space on one side.