Garrett Rooney <rooneg@electricjellyfish.net> writes:
> i did a little poking around with this a few days ago, and it's not
> promising...
>
> now that we've removed the path types, we're back to the problem that
> we pass quite a few url's into svn_path_canonicalize, and we don't
> have any way to determine how to handle them. removing extraneous .'s
> and ..'s isn't too hard, but removing redundant /'s is a bitch,
> because we have to be sure not to wipe out the // in the urls.
>
> if anyone has a good solution for this, i'd love to hear it. i don't
> want to return to passing path types into all the svn_path functions,
> and having some kind of heuristic to determine what to remove and what
> to leave just seems clunky and prone to failure.
I don't know if it's a *good* solution, but svn_path_canonicalize
could start calling svn_path_is_url() (which itself can use some
maturing) to test for URL-ness. Once URL-ness is discovered, the
simple rule could be that we will never remove any of the first three
'/'s in the path:
<scheme>://<optional_server>/path/on/server
| |
+------- "safe zone" -------+
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Oct 21 14:36:57 2006