develooper Front page | perl.perl5.porters | Postings from August 2012

[perl #114496] win32_getenv and perl_free under PERL_DESTRUCT_LEVEL=1 trys to access freed tmps_stack

Thread Next
From:
bulk 88 via RT
Date:
August 21, 2012 15:33
Subject:
[perl #114496] win32_getenv and perl_free under PERL_DESTRUCT_LEVEL=1 trys to access freed tmps_stack
Message ID:
rt-3.6.HEAD-11172-1345588374-1836.114496-15-0@perl.org
Is there a reason why 
_____________________________________
STATIC void
S_nuke_stacks(pTHX)
{
    dVAR;
    while (PL_curstackinfo->si_next)
	PL_curstackinfo = PL_curstackinfo->si_next;
    while (PL_curstackinfo) {
	PERL_SI *p = PL_curstackinfo->si_prev;
	/* curstackinfo->si_stack got nuked by sv_free_arenas() */
	Safefree(PL_curstackinfo->si_cxstack);
	Safefree(PL_curstackinfo);
	PL_curstackinfo = p;
    }
    Safefree(PL_tmps_stack);
    Safefree(PL_markstack);
    Safefree(PL_scopestack);
#ifdef DEBUGGING
    Safefree(PL_scopestack_name);
#endif
    Safefree(PL_savestack);
}
________________________________
doesn't NULL out the pointers? because of PERL_POISON? Yet in
perl_destruct I often see a Safefree followed by a null assignment. What
is correct?

---
via perlbug:  queue: perl5 status: new
https://rt.perl.org:443/rt3/Ticket/Display.html?id=114496

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About