mirror of
https://github.com/git/git
synced 2024-08-27 19:49:21 +00:00
Merge branch 'lb/contrib-contacts-looser-diff-parsing'
* lb/contrib-contacts-looser-diff-parsing: git-contacts: do not fail parsing of good diffs
This commit is contained in:
commit
ed27751961
|
@ -96,8 +96,6 @@ sub scan_patches {
|
|||
next unless $id;
|
||||
if (m{^--- (?:a/(.+)|/dev/null)$}) {
|
||||
$source = $1;
|
||||
} elsif (/^--- /) {
|
||||
die "Cannot parse hunk source: $_\n";
|
||||
} elsif (/^@@ -(\d+)(?:,(\d+))?/ && $source) {
|
||||
my $len = defined($2) ? $2 : 1;
|
||||
push @{$sources->{$source}{$id}}, [$1, $len] if $len;
|
||||
|
|
Loading…
Reference in a new issue