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

RE: svn commit: r983766 - /subversion/branches/performance/subversion/libsvn_client/export.c

From: Bert Huijben <bert_at_vmoo.com>
Date: Mon, 9 Aug 2010 21:04:45 +0200

> -----Original Message-----
> From: Daniel Shahaf [mailto:d.s_at_daniel.shahaf.name]
> Sent: maandag 9 augustus 2010 20:45
> To: dev_at_subversion.apache.org
> Cc: stefan2_at_apache.org
> Subject: Re: svn commit: r983766 -
> /subversion/branches/performance/subversion/libsvn_client/export.c
>
> stefan2_at_apache.org wrote on Mon, Aug 09, 2010 at 18:33:53 -0000:
> > Author: stefan2
> > Date: Mon Aug 9 18:33:53 2010
> > New Revision: 983766
> >
> > URL: http://svn.apache.org/viewvc?rev=983766&view=rev
> > Log:
> > Fix the root cause of an assertion triggered by exporting KDE /trunk:
> > File names need to be canonicalized when forming URLs.
> >
> > * subversion/libsvn_client/export.c
> > (add_file): properly escape the file's URL
> >
> > Modified:
> > subversion/branches/performance/subversion/libsvn_client/export.c
> >
> > Modified:
> subversion/branches/performance/subversion/libsvn_client/export.c
> > URL:
> http://svn.apache.org/viewvc/subversion/branches/performance/subversio
> n/libsvn_client/export.c?rev=983766&r1=983765&r2=983766&view=diff
> >
> ==========================================================
> ====================
> > --- subversion/branches/performance/subversion/libsvn_client/export.c
> (original)
> > +++ subversion/branches/performance/subversion/libsvn_client/export.c
> Mon Aug 9 18:33:53 2010
> > @@ -708,7 +708,12 @@ add_file(const char *path,
> > struct edit_baton *eb = pb->edit_baton;
> > struct file_baton *fb = apr_pcalloc(pool, sizeof(*fb));
> > const char *full_path = svn_dirent_join(eb->root_path, path, pool);
> > - const char *full_url = svn_uri_join(eb->root_url, path, pool);
> > +
> > + /* path is not canonicalized, i.e. it may still contain spaces etc.
*/
> > + const char *full_url =
svn_uri_canonicalize(svn_uri_join(eb->root_url,
> > + path,
> > + pool),
> > + pool);
> >
>
> See svn_path_url_add_component2().

This is a better approach then the one I suggested in my other mail as it
handles all in one call.

        Bert
Received on 2010-08-09 21:05:53 CEST

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