apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r..@covalent.net
Subject Re: [PATCH] RE: cvs commit: apr-util/buckets apr_buckets_file.c (fwd)
Date Fri, 16 Feb 2001 21:36:42 GMT



On Fri, 16 Feb 2001, Cliff Woolley wrote:

> > -----Original Message-----
> > From: rbb@covalent.net [mailto:rbb@covalent.net]
> > This was just committed to apr_util's bucket code.  This should fix the
> > mod_include problem (at least it did for me).  What was happening, was
> > that we read from the file, and converted it into a heap bucket.  Then, we
> > destroyed the file bucket (free'ing *s at the same time), and then we used
> > s->start to create the second file bucket.
> It occurred to me while I was at lunch that there's no need to destroy the
> shared+file bucket at all if we're going to turn around and create a new one
> anyway.  All we're missing is an apr_bucket struct to point to the
> shared+file bucket data we already have constructed.  Doing it this way
> removes about two frees and three mallocs and a bunch of unneeded pointer
> arithmetic from each file_read() call on non-MMAP platforms.  The patch is
> attached due to a line wrap munging.
> --Cliff

Ryan Bloom                        	rbb@apache.org
406 29th St.
San Francisco, CA 94131

View raw message