aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2006-12-11 20:25:58 -0800
committerJunio C Hamano <junkio@cox.net>2006-12-13 12:08:01 -0800
commit359850041e8158f6aeb70ad611ef1ba8834b8349 (patch)
tree5259fd8ee57830f4c1b8dbfc9af8f22f4fe57b47
parentf388cec3d77751a6c20b3b10415344f5355b5a2f (diff)
downloadgit-359850041e8158f6aeb70ad611ef1ba8834b8349.tar.gz
git-359850041e8158f6aeb70ad611ef1ba8834b8349.tar.xz
git-svn: correctly handle "(no author)" when using an authors file
The low-level parts of the SVN library return NULL/undef for author-less revisions, whereas "(no author)" is a (svn) client convention. Signed-off-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
-rwxr-xr-xgit-svn.perl3
1 files changed, 2 insertions, 1 deletions
diff --git a/git-svn.perl b/git-svn.perl
index 15254e479..ec92b440b 100755
--- a/git-svn.perl
+++ b/git-svn.perl
@@ -2981,7 +2981,8 @@ sub libsvn_log_entry {
my ($Y,$m,$d,$H,$M,$S) = ($date =~ /^(\d{4})\-(\d\d)\-(\d\d)T
(\d\d)\:(\d\d)\:(\d\d).\d+Z$/x)
or die "Unable to parse date: $date\n";
- if (defined $_authors && ! defined $users{$author}) {
+ if (defined $author && length $author > 0 &&
+ defined $_authors && ! defined $users{$author}) {
die "Author: $author not defined in $_authors file\n";
}
$msg = '' if ($rev == 0 && !defined $msg);