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

Re: svn commit: r1101091 - /subversion/trunk/subversion/libsvn_subr/cache-membuffer.c

From: Julian Foad <julian.foad_at_wandisco.com>
Date: Mon, 09 May 2011 17:40:58 +0100

stefan2_at_apache.org wrote:
> * subversion/libsvn_subr/cache-membuffer.c
> (MIN_SEGMENT_SIZE): ensure that cache sizes > 4GB work
> (svn_cache__membuffer_cache_create): formatting fixes; add missing cast

> /* allocate cache as an array of segments / cache objects */
> - c = apr_palloc(pool, segment_count * sizeof(*c));
> + c = (svn_membuffer_t *)apr_palloc(pool, segment_count * sizeof(*c));

Hi Stefan. In contrast to C++, in C it's a handy convenience that we
don't need to cast "void *" pointers before assigning them. This is the
only such cast in the code base.

- Julian
Received on 2011-05-09 18:41:33 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.