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

Re: crash with incomplete url

From: Stefan Küng <tortoisesvn_at_gmail.com>
Date: 2006-05-23 20:37:44 CEST

Peter N. Lundblad wrote:
> Malcolm Rowe writes:
> > On Tue, May 23, 2006 at 02:51:56PM +0200, Peter N. Lundblad wrote:
> > > My position on this is that svn_path_canonicalize should not crash fro
> > > any string, and no library function should crash on any string
> > > returned by svn_path_canonicalize.
> > >
> >
> > Strong +1 in theory, except: what should svn_path_canonicalize() do when
> > passed an invalid path or URL? There appears to be no way to return
> > an error.
> >
> Canonicalize according to its documentation. Invalid URLs need to be handled
> by the path functions. No one says we should crash on "hppt://foo/bar".

Haven't tested that url (hppt://foo/bar) if it crashes, but if it does,
then this proves my point:
a client can't check if this url is valid or not. Because it *is* a
valid url according to the specs, but Subversion doesn't recognize the
protocol? How would a client know that? For example, a user could add a
separate sub-protocol in the config files (e.g. svn+myencryption).
Should a client parse those files and see if maybe Subversion can handle
it? I don't think so, because that would mean a lot of
checking/configfilereading/stringparsing is done twice which is unnecessary.

Stefan

-- 
        ___
   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest Interface to (Sub)Version Control
    /_/   \_\     http://tortoisesvn.tigris.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue May 23 20:38:56 2006

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