Another possible approach (rather than getting the pool) is to have a function called apr_mmap_from_file() implemented in the file_io subtree. You can then pull the appropriate pool from the internal file structure and construct the mmap for that file.
Cheers, -g On Tue, Jan 02, 2001 at 01:26:54AM -0000, [EMAIL PROTECTED] wrote: > rbb 01/01/01 17:26:54 > > Modified: src/buckets ap_buckets_file.c > Log: > Use the same pool to allocate the mmap that was used to create the > original file. > > Revision Changes Path > 1.18 +3 -1 apr-util/src/buckets/ap_buckets_file.c > > Index: ap_buckets_file.c > =================================================================== > RCS file: /home/cvs/apr-util/src/buckets/ap_buckets_file.c,v > retrieving revision 1.17 > retrieving revision 1.18 > diff -u -r1.17 -r1.18 > --- ap_buckets_file.c 2001/01/01 00:33:42 1.17 > +++ ap_buckets_file.c 2001/01/02 01:26:53 1.18 > @@ -53,6 +53,7 @@ > */ > > #include "apr.h" > +#include "apr_general.h" > #include "apr_lib.h" > #include "apr_file_io.h" > #include "ap_buckets.h" > @@ -103,8 +104,9 @@ > /* we need to protect ourselves in case we die while we've got the > * file mmapped */ > apr_status_t status; > + apr_pool_t *p = APR_GET_POOL(f); > if ((status = apr_mmap_create(&mm, f, a->offset, e->length, > - APR_MMAP_READ, NULL)) != > APR_SUCCESS) { > + APR_MMAP_READ, p)) != APR_SUCCESS) { > mm = NULL; > } > } > > > -- Greg Stein, http://www.lyra.org/