aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorFabio Estevam <fabio.estevam@freescale.com>2014-12-10 18:51:40 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2014-12-10 20:41:11 -0500
commit15160f90b8640b7d83ec8cdac64c65403355faa6 (patch)
tree43eec7a6f315dffd884646812caf55713430b1a1 /scripts
parent04941aa774320eb0118339c8cd11d7f1321e74d3 (diff)
checkpatch: improve warning message for "needless if" case
Add an 'and' to the sentence so that it looks better: WARNING: debugfs_remove(NULL) is safe and this check is probably not required Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Cc: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/checkpatch.pl2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index d94f5d879fb1..10ad5ab571dc 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -4446,7 +4446,7 @@ sub process {
4446 my $expr = '\s*\(\s*' . quotemeta($1) . '\s*\)\s*;'; 4446 my $expr = '\s*\(\s*' . quotemeta($1) . '\s*\)\s*;';
4447 if ($line =~ /\b(kfree|usb_free_urb|debugfs_remove(?:_recursive)?)$expr/) { 4447 if ($line =~ /\b(kfree|usb_free_urb|debugfs_remove(?:_recursive)?)$expr/) {
4448 WARN('NEEDLESS_IF', 4448 WARN('NEEDLESS_IF',
4449 "$1(NULL) is safe this check is probably not required\n" . $hereprev); 4449 "$1(NULL) is safe and this check is probably not required\n" . $hereprev);
4450 } 4450 }
4451 } 4451 }
4452 4452