Skip to content

Commit

Permalink
get_maintainer.pl: find maintainers for removed files
Browse files Browse the repository at this point in the history
For removed files, get_maintainer.pl doesn't find any maintainers (besides
the default [email protected]), as it only looks at the "+++"
lines, which are "/dev/null" for removals.  Fix this by extending the
parsing to the "---" lines.

E.g. for the two line test patch below the real score maintainers will now
be found:

    --- a/arch/score/include/asm/dma-mapping.h
    +++ /dev/null

Signed-off-by: Geert Uytterhoeven <[email protected]>
Cc: Joe Perches <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
geertu authored and torvalds committed Feb 22, 2013
1 parent 36d308d commit 6be0710
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/get_maintainer.pl
Original file line number Diff line number Diff line change
Expand Up @@ -433,7 +433,7 @@ sub read_mailmap {

while (<$patch>) {
my $patch_line = $_;
if (m/^\+\+\+\s+(\S+)/) {
if (m/^\+\+\+\s+(\S+)/ or m/^---\s+(\S+)/) {
my $filename = $1;
$filename =~ s@^[^/]*/@@;
$filename =~ s@\n@@;
Expand Down

0 comments on commit 6be0710

Please sign in to comment.