Skip to content

Commit

Permalink
git-svn bug with blank commits and author file
Browse files Browse the repository at this point in the history
When trying to import from svn using an author file, git-svn bails out
if it encounters a blank author. The attached patch changes this
behavior and allow using the author file with blanks authors.

I came across this bug while importing from a cvs2svn repo where the
initial revision (1) has a blank author. This doesn't break the behavior
of bailing out when an unknown author is encountered.

Acked-by: Eric Wong <[email protected]>

Signed-off-by: Junio C Hamano <[email protected]>
  • Loading branch information
dermoth authored and gitster committed Apr 23, 2008
1 parent 75b7dfb commit 9231f50
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions git-svn.perl
Original file line number Diff line number Diff line change
Expand Up @@ -2363,8 +2363,7 @@ sub check_author {
my ($author) = @_;
if (!defined $author || length $author == 0) {
$author = '(no author)';
}
if (defined $::_authors && ! defined $::users{$author}) {
} elsif (defined $::_authors && ! defined $::users{$author}) {
die "Author: $author not defined in $::_authors file\n";
}
$author;
Expand Down

0 comments on commit 9231f50

Please sign in to comment.