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

Re: svn commit: r1083817 - /subversion/trunk/subversion/libsvn_wc/wc_db.c

From: Hyrum K Wright <hyrum_at_hyrumwright.org>
Date: Mon, 21 Mar 2011 18:23:03 -0500

On Mon, Mar 21, 2011 at 10:02 AM, <rhuijben_at_apache.org> wrote:
> Author: rhuijben
> Date: Mon Mar 21 15:02:27 2011
> New Revision: 1083817
>
> URL: http://svn.apache.org/viewvc?rev=1083817&view=rev
> Log:
> * subversion/libsvn_wc/wc_db.c
>  (svn_wc__db_read_conflicts): Reset statement on error.
>
> Modified:
>    subversion/trunk/subversion/libsvn_wc/wc_db.c
>
> Modified: subversion/trunk/subversion/libsvn_wc/wc_db.c
> URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/wc_db.c?rev=1083817&r1=1083816&r2=1083817&view=diff
> ==============================================================================
> --- subversion/trunk/subversion/libsvn_wc/wc_db.c (original)
> +++ subversion/trunk/subversion/libsvn_wc/wc_db.c Mon Mar 21 15:02:27 2011
> @@ -8189,12 +8189,17 @@ svn_wc__db_read_conflicts(const apr_arra
>         {
>           const svn_wc_conflict_description2_t *desc;
>           const svn_skel_t *skel;
> +          svn_error_t *err;
>
>           skel = svn_skel__parse(conflict_data, strlen(conflict_data),
>                                  scratch_pool);
> -          SVN_ERR(svn_wc__deserialize_conflict(&desc, skel,
> +          err = svn_wc__deserialize_conflict(&desc, skel,
>                           svn_dirent_dirname(local_abspath, scratch_pool),
> -                          result_pool, scratch_pool));
> +                          result_pool, scratch_pool);
> +
> +          if (err)
> +            SVN_ERR(svn_error_compose_create(err,
> +                                             svn_sqlite__reset(stmt)));

No need to use SVN_ERR() above. You've already established that
there's and error which you should return; just go ahead and return
the result of the compose.

>
>           APR_ARRAY_PUSH(cflcts, const svn_wc_conflict_description2_t *) = desc;
>         }
>
>
>
Received on 2011-03-22 00:23:36 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.