[svk-users] SVK mirror sync problem - quoted spaces in url

Fabian Walk f.walk at maul-theet.de
Tue Apr 15 06:07:26 EDT 2008


Hi,

Cheng-Lung Sung schrieb:
> Hi,
>     Can you apply this patch and try again?

I have apply the patch and run the following test cases.

It seems that in case 3 and 4 the spaces in the url and the %20 that is 
converted via the patch to spaces cause problems in the SVNRa module 
when I use http instead of file as protocol.


test case 1 (file url double quotes):
=====================================
$ svk mi "file:///D:/User/Fabian/SCM/svn-testrep/Bruel and Kjaer" 
//mirror/BK
Mirror initialized.  Run svk sync //mirror/BK to start mirroring.

$ svk sync //mirror/BK
Syncing file:///D:/User/Fabian/SCM/svn-testrep/Bruel and Kjaer
Retrieving log information from 1 to 1
Committed revision 4 from revision 1.


test case 2 (file url quotes):
==============================
$ svk mi file:///D:/User/Fabian/SCM/svn-testrep/Bruel%20and%20Kjaer/ 
//mirror/BK
Mirror initialized.  Run svk sync //mirror/BK to start mirroring.

$ svk sync //mirror/BK
Syncing file:///D:/User/Fabian/SCM/svn-testrep/Bruel and Kjaer
Retrieving log information from 1 to 1
Committed revision 4 from revision 1.


test case 3 (http url double quotes):
=====================================
$ svk mi "http://svn.maul-theet.de/Bruel and Kjaer/" //mirror/BK
Bad URL passed to RA layer: Malformed URL for repository


test case 4 (http url quotes):
==============================
$ svk mi http://svn.maul-theet.de/Bruel%20and%20Kjaer/ //mirror/BK
Bad URL passed to RA layer: Malformed URL for repository


> 
> ==================================================================
> --- lib/SVK/Mirror.pm   (revision 2736)
> +++ lib/SVK/Mirror.pm   (local)
> @@ -118,6 +118,7 @@
>      my $self = $class->SUPER::new($args);
> 
>      $self->{url} =~ s{/+$}{}g;
> +    $self->{url} =~ s/%([0-9A-Fa-f]{2})/chr(hex($1))/eg;
> 
>      $self->pool( SVN::Pool->new(undef) )
>          unless $self->pool;
> ==================================================================


More information about the svk-users mailing list