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

Re: canonicalized path hits assertion

From: Stefan Kueng <tortoisesvn_at_gmail.com>
Date: Mon, 29 Dec 2008 18:28:41 +0100

Stefan Sperling wrote:
> On Mon, Dec 29, 2008 at 02:48:12PM +0100, Stefan Kueng wrote:
>> Hi,
>> Using an svn client built from trunk, trying to access a repository on a
>> Windows network share
>> $ svn list file://SERVER/svn/TestRepo
>> will hit the assertion
>> assert(svn_path_is_canonical());
>> since svn_path_is_canonical() thinks that url is not canonical.
> That check must be wrong, so. I'd like to fix this, but have
> no access to Windows. Can you fix it?

Committed a fix in r34963.

> On Unix, this fails with:
> $ svn list file://SERVER/svn/TestRepo
> subversion/libsvn_ra_local/ra_plugin.c:454: (apr_err=170000)
> svn: Unable to open an ra_local session to URL
> subversion/libsvn_ra_local/split_url.c:123: (apr_err=170000)
> svn: Local URL 'file://server/svn/TestRepo' contains unsupported hostname
> From reading the code, that failure is what we expect to happen.
>> If I build the client in release mode with the assertions disabled, the
>> list command works as it should. But the many, many assertions in debug
>> mode are really annoying.
> Then please convert all remaining asserts to either SVN_ERR_ASSERT_NO_RETURN
> (for functions which do not return svn_error_t *, see r34334)
> or SVN_ERR_ASSERT (for functions which return svn_error_t *).

There are a lot of assert() calls left. I'm not sure whether it is safe
to change all of them to SVN_ERR_ASSERT_NO_RETURN - that macro calls
abort() after calling the custom handler. A simple assert() would do
nothing in a release build, so changing all those to abort() doesn't
seem like a good idea.
I suggest changing those one by one, by those who are familiar with the
code part (there are a lot in the fs_ libs, and I'm not comfortable
changing those because that could lead to aborting a server).


  oo  // \\      "De Chelonian Mobile"
 (_,\/ \_/ \     TortoiseSVN
   \ \_/_\_/>    The coolest Interface to (Sub)Version Control
   /_/   \_\     http://tortoisesvn.net

Received on 2008-12-29 18:29:12 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.