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

Re: [PATCH] Fix failing ci caused in r40202

From: Julian Foad <julianfoad_at_btopenworld.com>
Date: Tue, 22 Dec 2009 11:36:09 +0000

Kannan wrote:
> Julian Foad wrote:
> > do_checkout():
> > ...
> > *locn = svn_ra_neon__request_get_location(request, pool);
> >
> > checkout_resource():
> > do_checkout(cc, rsrc->vsn_url, allow_404, token, &code, &locn, pool);
> > ne_uri_parse(locn, &parse);
> > rsrc->wr_url = svn_uri_canonicalize(parse.path, rsrc->pool);
> >
> > Does the "ne_uri_parse" function create a non-canonical ".path", or does
> > the do_checkout() function create a non-canonical URL?
>
> `do_checkout()' creates the non-canonical URL, after which the scheme,
> host, port and path of the URL are stored as separate members in 'parse'
> using `ne_uri_parse()'.

OK. The policy in Subversion is that the paths and URLs passed in and
out of all APIs are canonical unless otherwise stated. Therefore we
should make do_checkout() set its "locn" output parameter to a canonical
URL.

> > If the former, we should look for all other uses of ne_uri_parse() and
> > canonicalize after them as well. If the latter, we should fix the
> > do_checkout() function and look for all other uses of
> > svn_ra_neon__request_get_location().

Oops - when I wrote that, I was thinking
svn_ra_neon__request_get_location() was an external (non-Subversion)
function, but it is a Subversion function so it should return a
canonical URL.

> Does this imply to make `svn_ra_neon__request_get_location()' create a
> non-canonical URL by default?

No, it should create a canonical URL. The fix we need is inside
svn_ra_neon__request_get_location(), or at least we need to look inside
that function to see where the non-canonical URL is coming from, and
maybe trace further back to find the cause of the problem.

> > (What does the non-canonical URL or URI look like?)
>
> http://localhost/repos/devrepo/!svn/wrk/b4ec0dff-9abf-42ee-8860-a6a9630218e4/
>
> (which is generated by do_checkout() and parse.path value would be:
>
> /repos/devrepo/!svn/wrk/b4ec0dff-9abf-42ee-8860-a6a9630218e4/ )

Thanks.

- Julian
Received on 2009-12-22 12:38:14 CET

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.