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

Re: svn commit: r12099 - branches/locking/subversion/mod_dav_svn

From: Ben Collins-Sussman <sussman_at_collab.net>
Date: 2004-12-01 16:41:21 CET

On Nov 30, 2004, at 4:16 PM, Philip Martin wrote:

> sussman@tigris.org writes:
>
>> --- branches/locking/subversion/mod_dav_svn/repos.c (original)
>> +++ branches/locking/subversion/mod_dav_svn/repos.c Tue Nov 30
>> 15:56:39 2004
>> @@ -1376,9 +1376,31 @@
>> "software.");
>> }
>>
>
> This function has no documentation.

Will fix.

>
>> +
>> +static const char *get_parent_path(const char *path,
>> + apr_pool_t *pool)
>> +{
>> + apr_size_t len;
>> + const char *parentpath, *basename;
>> + char *tmp = apr_pstrdup(pool, path);
>> +
>> + /* Remove any trailing slash; they make svn_path_split() assert
>> and die.*/
>
> Why are non-canonical paths being passed around?

Good question. It seems to be part of the mystery of mod_dav_svn's
complicated internal structures. Though it's not fs-paths or wc-paths
that have trailing slashes -- it seems to be only fields that hold
URIs (or chunks of URIs), things like

       /repos/!svn/bln/39/blah/

>
>> + len = strlen(tmp);
>> + if (tmp[len-1] == '/')
>
> Since I don't know if "" is a valid input I don't know whether [len-1]
> is safe.
>
>

Thanks, will fix.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Dec 1 17:05:41 2004

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.