git-svn: avoid fetching files outside of the URL we're tracking
PATCH 1/1 git-svn: avoid fetching files outside of the URL we're tracking
Thanks to Santi <[email protected]> for the bug report and explanation:
Quoted 2 lines
/path/to/repository/project/file
/path/to/repository/project-2/file
<...>
Quoted 4 lines
you end up with a project with the following files:
file
-2/file
Signed-off-by Eric Wong <[email protected]>
--- contrib/git-svn/git-svn.perl | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
contrib/git-svn/git-svn.perl +1 -1
@@ -2625,7 +2625,7 @@ sub libsvn_connect { sub libsvn_get_file { my ($gui, $f, $rev) = @_; my $p = $f; - return unless ($p =~ s#^\Q$SVN_PATH\E/?##); + return unless ($p =~ s#^\Q$SVN_PATH\E/##); my ($hash, $pid, $in, $out); my $pool = SVN::Pool->new;
Signature · 1 line
1.4.1.ge255