When files are added or removed /dev/null is used as a place
holder name in the patch for the absent file.  Don't try and
find a MAINTAINER for this place holder, it only ever flags
and then spams THE REST.

Signed-off-by: Alan Robinson <alan.robin...@ts.fujitsu.com>
---

Tested by pretending to remove xen/common/cpupool.c for
which get_maintainers.pl currently flags 11 addresses, after
this patch only xen-devel and its two maintainers (Juergen and
Dario) get listed...

 scripts/get_maintainer.pl | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/scripts/get_maintainer.pl b/scripts/get_maintainer.pl
index 0ce2d367fa..277ba17a67 100755
--- a/scripts/get_maintainer.pl
+++ b/scripts/get_maintainer.pl
@@ -447,7 +447,9 @@ foreach my $file (@ARGV) {
                $filename =~ s@^[^/]*/@@;
                $filename =~ s@\n@@;
                $lastfile = $filename;
-               push(@files, $filename);
+               if ($filename ne "dev/null") { #Ignore the no-file placeholder
+                    push(@files, $filename);
+               }
                $patch_prefix = "^[+-].*";      #Now parsing the actual patch
            } elsif (m/^\@\@ -(\d+),(\d+)/) {
                if ($email_git_blame) {
-- 
2.14.1

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

Reply via email to