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

Re: svn commit: r1340874 - /subversion/trunk/subversion/libsvn_fs_fs/fs_fs.c

From: Greg Stein <gstein_at_gmail.com>
Date: Mon, 21 May 2012 00:11:28 -0400

On Sun, May 20, 2012 at 8:14 PM, <stefan2_at_apache.org> wrote:
>...
> +++ subversion/trunk/subversion/libsvn_fs_fs/fs_fs.c Mon May 21 00:14:20 2012
>...
> +              const char *path;
> +              apr_ssize_t klen;
> +              apr_hash_this(hi, (const void **)&path, &klen, NULL);

Historically, we have not allowed casts like this. Please switch the
PATH localvar to void* and drop the cast. The rest of the function
will work fine with path as a void*.

> +
> +              /* If we come across a child of our path, remove it.
> +                 Call svn_dirent_is_child only if there is a chance that
> +                 this is actually a sub-path.
> +               */
> +              if (   klen >= min_child_len
> +                  && svn_dirent_is_child(change->path, path, iterpool))
>                 apr_hash_set(changed_paths, path, klen, NULL);
>             }
>         }

Cheers,
-g
Received on 2012-05-21 06:12:04 CEST

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.