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

Re: svn commit: r1588899 - /subversion/trunk/subversion/libsvn_fs_fs/transaction.c

From: Ivan Zhakov <ivan_at_visualsvn.com>
Date: Mon, 21 Apr 2014 19:24:46 +0400

On 21 April 2014 19:18, <stefan2_at_apache.org> wrote:
> Author: stefan2
> Date: Mon Apr 21 15:18:54 2014
> New Revision: 1588899
>
> URL: http://svn.apache.org/r1588899
> Log:
> Be consistent in the way we create file / stream data buffers.
>
> * subversion/libsvn_fs_fs/transaction.c
> (fnv1a_checksum_on_file_range): Allocate the data buffer from the
> APR pool instead of from stack.
>
> Modified:
> subversion/trunk/subversion/libsvn_fs_fs/transaction.c
>
> Modified: subversion/trunk/subversion/libsvn_fs_fs/transaction.c
> URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_fs_fs/transaction.c?rev=1588899&r1=1588898&r2=1588899&view=diff
> ==============================================================================
> --- subversion/trunk/subversion/libsvn_fs_fs/transaction.c (original)
> +++ subversion/trunk/subversion/libsvn_fs_fs/transaction.c Mon Apr 21 15:18:54 2014
> @@ -3567,7 +3567,7 @@ fnv1a_checksum_on_file_range(apr_uint32_
> apr_off_t size,
> apr_pool_t *pool)
> {
> - char buffer[SVN__STREAM_CHUNK_SIZE];
> + char *buffer = apr_pcalloc(pool, SVN__STREAM_CHUNK_SIZE);
>
Hi Stefan,

Thanks for quick fix, but usually we use apr_palloc() instead of
apr_pCalloc for read buffers.

-- 
Ivan Zhakov
CTO | VisualSVN | http://www.visualsvn.com
Received on 2014-04-21 17:25:37 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.