[PATCH 2/8] checkpatch: do not warn about -p0 patches when checking files
- From: Andy Whitcroft <apw@xxxxxxxxxxxxx>
- Date: Fri, 30 Jan 2009 15:05:14 +0000
We are triggering the -p0 check for our own diffs generated using
--file command line option. Suppress this check for files.
Signed-off-by: Andy Whitcroft <apw@xxxxxxxxxxxxx>
---
scripts/checkpatch.pl | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index c71a0fa..5ffc940 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -1240,7 +1240,8 @@ sub process {
$realfile =~ s@^([^/]*)/@@;
$p1_prefix = $1;
- if ($tree && $p1_prefix ne '' && -e "$root/$p1_prefix") {
+ if (!$file && $tree && $p1_prefix ne '' &&
+ -e "$root/$p1_prefix") {
WARN("patch prefix '$p1_prefix' exists, appears to be a -p0 patch\n");
}
--
1.6.1.2.419.g0d87e
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
- References:
- [PATCH 0/8] update checkpatch to v0.28
- From: Andy Whitcroft
- [PATCH 0/8] update checkpatch to v0.28
- Prev by Date: [PATCH 7/8] checkpatch: add __ref as a sparse modifier
- Next by Date: [PATCH 5/8] checkpatch: a modifier is not an identifier at the end of a type
- Previous by thread: [PATCH 7/8] checkpatch: add __ref as a sparse modifier
- Next by thread: [PATCH 5/8] checkpatch: a modifier is not an identifier at the end of a type
- Index(es):
Relevant Pages
|
Loading