You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Steve Hay <st...@googlemail.com> on 2014/11/03 09:44:53 UTC

Re: A patch to fix one sort of mod_perl crash I've been experiencing.

On 31 October 2014 08:47, Steve Hay <st...@googlemail.com> wrote:
> On 4 June 2014 21:02, Kandarian, Richard M <ri...@lanl.gov> wrote:
>> Reading MP_TRACE messages I noticed that for every modperl_interp_select() call during a request there were two modperl_interp_unselect() calls, one bracketing the _select() call and one from the registered cleanup when the pool was destroyed. The attached patch stopped those crashes. I would call my fix VERY tentative  for various reasons including my noobiness and I've added comments near the active ingredient in modperl_interp.c. Inactive ingredients include diffs in the patch which are my adding trace info.
>>
>
> Apologies for the long delay in following up on this.
>
[...]
>
> I will ask Jan Kaluza about the refcnt business since he authored the
> change I cited above which dropped the refcnt decrement in the case
> where refcnt is 1.

After speaking with Jan, I have now committed the second patch above
in r1636289.

(We think that the refcnt change alone should fix your crash, but it
doesn't hurt to have the extra safety net of the early return if the
interp is already unselected, although that shouldn't happen now.)

Many thanks for your work on this.