Mladen Turk wrote:
> I already proposed a solution to this problem few months ago.
> IMO the solution is to have two cleanup callback lists and an
> api that could mark the callback as pre-subpool-destroy.
>
> So instead having:
> apr_pool_destroy/clear {
> destroy_all_subpools
> run_cleanup_callbacks
> }
>
> we would have:
> apr_pool_destroy/clear {
> run_pred_cleanup_callbacks
> destroy_all_subpools
> run_post_cleanup_callbacks
> }
Yes, thank you, that would work nicely! If apr_reslist_create()
registered its cleanup function as a pre-cleanup, I think it would
work just as you say; existing users of reslists who might have
apr_pool_destroy() in their destructors wouldn't need to alter
anything. I guess this fix would require a joint release of
APR and APR-util ... how does that work, BTW?
Chris.
--
GPG Key ID: 366A375B
GPG Key Fingerprint: 485E 5041 17E1 E2BB C263 E4DE C8E3 FA36 366A 375B