From 9a2bb059e76b1368392f86ecf7af2ba188e3cac5 Mon Sep 17 00:00:00 2001 From: Ramkumar Ramachandra Date: Sat, 10 Jan 2015 09:35:10 -0500 Subject: Git::SVN: handle missing ref_id case correctly ref_id should not match "refs/remotes/". [ew: dropped initial hunk for GIT_SVN_ID at Ramkumar's request] Signed-off-by: Ramkumar Ramachandra Signed-off-by: Eric Wong --- perl/Git/SVN.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'perl/Git') diff --git a/perl/Git/SVN.pm b/perl/Git/SVN.pm index d9a52a52d..8e4af7153 100644 --- a/perl/Git/SVN.pm +++ b/perl/Git/SVN.pm @@ -2365,7 +2365,7 @@ sub _new { # Older repos imported by us used $GIT_DIR/svn/foo instead of # $GIT_DIR/svn/refs/remotes/foo when tracking refs/remotes/foo - if ($ref_id =~ m{^refs/remotes/(.*)}) { + if ($ref_id =~ m{^refs/remotes/(.+)}) { my $old_dir = "$ENV{GIT_DIR}/svn/$1"; if (-d $old_dir && ! -d $dir) { $dir = $old_dir; -- cgit v1.2.1