get_maintainers.pl: Avoid THE_REST when files are added or removed

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, behaviour for a real filename is
unchanged.

Signed-off-by: Alan Robinson <Alan.Robinson@ts.fujitsu.com>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
This commit is contained in:
Alan Robinson authored and Jan Beulich committed 2018-02-23 14:24:56 +01:00
1 parent f735cf5521
commit 140ddf18a6
1 file changed
+6 -4
+6 -4
View File
@@ -444,10 +444,12 @@ foreach my $file (@ARGV) {
my $patch_line = $_;
if (m/^\+\+\+\s+(\S+)/ or m/^---\s+(\S+)/) {
my $filename = $1;
$filename =~ s@^[^/]*/@@;
$filename =~ s@\n@@;
$lastfile = $filename;
push(@files, $filename);
if ($1 ne "/dev/null") { #Ignore the no-file placeholder
$filename =~ s@^[^/]*/@@;
$filename =~ s@\n@@;
$lastfile = $filename;
push(@files, $filename);
}
$patch_prefix = "^[+-].*"; #Now parsing the actual patch
} elsif (m/^\@\@ -(\d+),(\d+)/) {
if ($email_git_blame) {
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.