httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cliff Woolley <>
Subject Re: [PATCH (w/caveats)] mmap cleanup issue
Date Thu, 18 Apr 2002 21:17:49 GMT
On Thu, 18 Apr 2002, Brian Pane wrote:

> Forgive me if this has been considered already (I haven't had time
> to keep up with the mmap issues), but why not create a variant of
> apr_mmap_dup() that allocates space for a new apr_mmap_t from the
> brigade's bucket_alloc?  Then the brigade, rather than the pool,
> would control the lifetime of the dup'ed mmap.

I hadn't considered that, but I don't think it's possible anyway, for
two reasons:

 - very much of the code throughout APR, APR-util, and Apache assumes that
   the apr_mmap_t will be associated with a pool (mm->cntxt).
 - even if you modified your idea to allocate it out of the brigade's
   pool instead of the brigade's bucket_alloc, it still wouldn't work
   because buckets are not inherently tied to a single brigade; they
   can move freely from one brigade to the next.  the brigades might
   have different lifetimes.  Shorter, fine, but longer would get
   us into the same old problem.


   Cliff Woolley
   Charlottesville, VA

View raw message