[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: relative externals fail with spaces

From: Karl Fogel <kfogel_at_red-bean.com>
Date: Tue, 30 Sep 2008 12:16:31 -0400

Stefan Küng <tortoisesvn_at_gmail.com> writes:
> Hi,
>
> A user reported a problem with relative externals on the TSVN mailing list:
> http://tortoisesvn.tigris.org/servlets/ReadMsg?list=users&msgNo=14004
>
> Attached is a test repository which shows this problem. I've verified
> that the problem still exists in the Subversion trunk r33254, but only
> for http/https served repositories. The problem does not exist for
> file:/// or svn:// served repositories.
>
> To reproduce the problem, check out /trunk from the attached repository,
> which gives the error:
>
> Error: URL 'https://192.168.2.5/svn/extrepo/trunk/folder with
> space/libs/library1' is
> Error: malformed or the scheme or host or path is missing

Reproduced. I think I've got the fix (see diff below); testing now.

-Karl

Index: subversion/libsvn_client/externals.c
===================================================================
--- subversion/libsvn_client/externals.c (revision 33358)
+++ subversion/libsvn_client/externals.c (working copy)
@@ -1146,9 +1146,9 @@
   len = strlen(cb->to_path);
   if (ib.parent_dir[len] == '/')
     ++len;
- ib.parent_dir_url = svn_path_join(cb->from_url,
- ib.parent_dir + len,
- cb->pool);
+ ib.parent_dir_url = svn_path_url_add_component(cb->from_url,
+ ib.parent_dir + len,
+ cb->pool);
 
   /* We must use a custom version of svn_hash_diff so that the diff
      entries are processed in the order they were originally specified

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: dev-help_at_subversion.tigris.org
Received on 2008-09-30 18:16:47 CEST

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.