apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bojan Smojver <bo...@rexursive.com>
Subject Re: Changing the order of cleanup for some core objects
Date Tue, 22 Jul 2008 10:02:31 GMT
On Tue, 2008-07-22 at 11:11 +0200, Mladen Turk wrote:

> If the user creates a subpool the problem will still be present because
> this sub pool will be destroyed before the destructor is called.
> Also any resource allocated from this pool will be destroyed in advance
> to the destructor (since its registered first, it'll be called last),
> while for apr_reslist_invalidate it won't.
> Don't think that'll work.

Given that reslist's code would then be in control of the pointer to the
sub-pool in question through apr_res_t, it can always make sure that one
of its internal cleanups resets that pointer to zero, so that destructor
doesn't destroy the pool again (if that ever occurs). Essentially, the
approach from that memcache patch and mod_dbd is implemented here
internally by reslist.


View raw message