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

Re: svn commit: r1394346 - /subversion/trunk/subversion/libsvn_ra_svn/client.c

From: C. Michael Pilato <cmpilato_at_collab.net>
Date: Thu, 4 Oct 2012 22:03:41 -0400

On 10/04/2012 09:55 PM, stefan2_at_apache.org wrote:
> Author: stefan2
> Date: Fri Oct 5 01:54:59 2012
> New Revision: 1394346
>
> URL: http://svn.apache.org/viewvc?rev=1394346&view=rev
> Log:
> * subversion/libsvn_ra_svn/client.c
> (ra_svn_commit): initialize *all* members of the ccb struct
>
> Modified:
> subversion/trunk/subversion/libsvn_ra_svn/client.c
>
> Modified: subversion/trunk/subversion/libsvn_ra_svn/client.c
> URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_ra_svn/client.c?rev=1394346&r1=1394345&r2=1394346&view=diff
> ==============================================================================
> --- subversion/trunk/subversion/libsvn_ra_svn/client.c (original)
> +++ subversion/trunk/subversion/libsvn_ra_svn/client.c Fri Oct 5 01:54:59 2012
> @@ -1044,6 +1044,7 @@ static svn_error_t *ra_svn_commit(svn_ra
> ccb = apr_palloc(pool, sizeof(*ccb));
> ccb->sess_baton = sess_baton;
> ccb->pool = pool;
> + ccb->new_rev = NULL;
> ccb->callback = callback;
> ccb->callback_baton = callback_baton;

We pretty commonly use apr_pcalloc() for exactly this reason. Yeah, it may
cost an extra couple of nanoseconds, but...

-- 
C. Michael Pilato <cmpilato_at_collab.net>
CollabNet   <>   www.collab.net   <>   Enterprise Cloud Development

Received on 2012-10-05 04:04:18 CEST

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