apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brian Pane <bri...@apache.org>
Subject Re: apr_palloc: What about apr_pfree?
Date Wed, 25 Jun 2003 07:19:10 GMT
The pool design currently can't support this.  It's optimized
for allocation speed; in the common case, apr_palloc requires
only a pointer addition.  The downside of this design is that
there's no way to reclaim memory within a pool.

There's been talk in the past of trying a more general-purpose
allocator design, or a system to allow different allocators to
be plugged in on a per-pool basis, but there's nothing like that
in the code yet.

Brian

HOR wrote:

>	Hi,
>
>	There is a possibility of the APR team add a function like
>
>/** Free the given pointer.  */
>APR_DECLARE(void *) apr_pfree(apr_pool_t *pool, void *pointer)
>
>to the current pool system? AFAIK it is only possible to deallocate memory 
>deallocating the whole pool.
>
>	I missing something obvious here?!
>
>	Thanks in advance
>
>	HOR
>  
>



Mime
View raw message