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

Re: svn commit: r921713 - /subversion/trunk/subversion/libsvn_subr/mergeinfo.c

From: Greg Stein <gstein_at_gmail.com>
Date: Thu, 11 Mar 2010 03:18:28 -0500

On Thu, Mar 11, 2010 at 02:54, <julianfoad_at_apache.org> wrote:
> Author: julianfoad
> Date: Thu Mar 11 07:54:16 2010
> New Revision: 921713
>
> URL: http://svn.apache.org/viewvc?rev=921713&view=rev
> Log:
> Simplify two mergeinfo functions.
>
> * subversion/libsvn_subr/mergeinfo.c
>  (svn_mergeinfo_inheritable): Replace the body with a call to
>    svn_mergeinfo_inheritable2().

This function, along with svn_rangelist_inheritable should be marked
as SVN_DEPRECATED in the header file. We may have caught this
duplicative logic earlier.

Further, these deprecated functions should move to libsvn_subr/deprecated.c

>...
> +++ subversion/trunk/subversion/libsvn_subr/mergeinfo.c Thu Mar 11 07:54:16 2010
>...
> @@ -1988,13 +1963,9 @@ svn_mergeinfo__filter_mergeinfo_by_range
>             {
>               apr_array_header_t *new_rangelist;
>
> -              if (include_range)
> -                SVN_ERR(svn_rangelist_intersect(&new_rangelist, rangelist,
> -                                                filter_rangelist, FALSE,
> -                                                result_pool));
> -              else
> -                SVN_ERR(svn_rangelist_remove(&new_rangelist, filter_rangelist,
> -                                             rangelist, FALSE, result_pool));
> +              SVN_ERR(rangelist_intersect_or_remove(
> +                        &new_rangelist, filter_rangelist, rangelist,
> +                        ! include_range, FALSE, result_pool));

The intersect call had (rangelist, filter_rangelist), but the remove
is opposite that. Yet the internal function passes along the one,
consistent ordering. Are you sure that is not a problem?

IOW, they all end up at rangelist_intersect_or_remove(), but you have
changed the order for the include_range==TRUE (intersect) case.

Cheers,
-g
Received on 2010-03-11 09:18:57 CET

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