On Sat May 21 09:25:10 2005, nicholas wrote: > There is a bug in duping - GvHV() can end up pointing at garbage. > > If I add this assertion to gv.c (*without* my recent HV changes, so > this > bug predates them): > > --- gv.c.orig Sat May 21 04:25:40 2005 > +++ gv.c Sat May 21 13:44:49 2005 > @@ -1304,7 +1304,12 @@ Perl_gp_free(pTHX_ GV *gv) > > if (gp->gp_sv) SvREFCNT_dec(gp->gp_sv); > if (gp->gp_av) SvREFCNT_dec(gp->gp_av); > + /* FIXME - another reference loop GV -> symtab -> GV ? > + Somehow gp->gp_hv can end up pointing at freed garbage. */ > if (gp->gp_hv) { > + if (SvTYPE(gp->gp_hv) != SVTYPEMASK) { > + assert(SvTYPE(gp->gp_hv) == SVt_PVHV); > + } > if (PL_stashcache && HvNAME(gp->gp_hv)) > hv_delete(PL_stashcache, > HvNAME(gp->gp_hv), strlen(HvNAME(gp->gp_hv)), > > > then various thread-creating tests fail during global destruction: Since :unique has been made a no-op, this can’t happen any more, so I’m marking this as resolved. If I’m wrong, somebody please re-open it.