On Nov 26, 2005, at 2:08 AM, Joe Orton wrote:

On Fri, Nov 25, 2005 at 08:18:51PM -0800, Brian Pane wrote:

I think the usual reason that the apr_palloc+memset pattern is
used instead of apr_pcalloc in httpd and APR code is to allow
the compiler generate inline code to fill the structure with zeros.

apr_pcalloc has been a macro for quite a long time now :)

#define apr_pcalloc(p, size) memset(apr_palloc(p, size), 0, size)

And according to the commit log, I probably should
have remembered that. :-)
http://svn.apache.org/viewcvs?rev=63357&view=rev

Brian

Reply via email to