On Mon, Feb 6, 2012 at 7:00 PM, Ronen Mizrahi <ro...@tversity.com> wrote:
>
>
> On Mon, Feb 6, 2012 at 6:54 PM, Bojan Smojver <bo...@rexursive.com> wrote:
>>
>> On Mon, 2012-02-06 at 18:47 -0500, Ronen Mizrahi wrote:
>> > For the time being we resolved it by adding an if not NULL statement
>> > before invoking the cleanup function however I am not sure that a NULL
>> > cleanup function is allowed or by itself represents some kind of an
>> > issue.
>>
>> Have you tried setting you cleanup function to apr_pool_cleanup_null()?
>> See:
>>
>>
>> http://apr.apache.org/docs/apr/1.4/group___pool_cleanup.html#gaa211acee585df08f396a50b0ea489b02
>>
>> --
>> Bojan
>>
>
> I am afraid I do not understand how this is relevant.

It is not valid to pass NULL for a cleanup function.
>
> The pool cleanup functions in the parent process are registered correctly
> and work fine even when releasing the global pool (which happens when the
> process terminates).
>
> Only in the child process we run into this issue and we cannot change the
> registrations of cleanup functions in the child process since the crash
> occurs somewhere between the invocation of fork() and the invocation of
> exec().

It is the registration in the parent which matters.  Please confirm
that you use apr_pool_cleanup_null() as the cleanup function whenever
you don't have any code to run.

>
> Ronen
>



-- 
Born in Roswell... married an alien...

Reply via email to