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

Re: Path canonicalization assertion failure triggered by add_dir_recursively()

From: Daniel Rall <dlr_at_collab.net>
Date: 2005-10-28 22:51:40 CEST

On Fri, 28 Oct 2005, Philip Martin wrote:

> Daniel Rall <dlr@collab.net> writes:
...
> > The error occurs because "." is passed to svn_wc_is_adm_dir(), which
> > eventually triggers the is_canonical() assertion failure in
> > svn_path_basename(). add_dir_recursive(), the caller of
> > svn_wc_is_adm_dir(), contains code which filters out empty, parent,
> > and "." paths, but that code isn't executed in time.
>
> "." isn't a canonical path. I think the error is that svn_io_dir_read
> should not be returning ".", it should convert it to "".

svn_io_dir_read() is documented as a thin wrapper around
apr_dir_read(). Two things:

1) There are other functions (e.g. svn_io_get_dirents2) which might be
more appropriate here because they already filter out "." and "..".

2) Should the semantics of svn_io_dir_read() change such that it
always does path canonicalization?

-- 
Daniel Rall
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Oct 28 22:52:30 2005

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.