From: Steve Hay Date: Mon, 11 Jul 2005 13:29:37 +0000 (+0100) Subject: Re: Scalar leaked in 'local $0' under ithreads + taint mode X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=d419787aba7043c27741cb1497c553fcd3241d02;p=p5sagit%2Fp5-mst-13.2.git Re: Scalar leaked in 'local $0' under ithreads + taint mode Message-ID: <42D26631.1070500@uk.radan.com> p4raw-id: //depot/perl@25123 --- diff --git a/sv.c b/sv.c index 3d17b1d..4e25290 100644 --- a/sv.c +++ b/sv.c @@ -11373,6 +11373,10 @@ perl_clone_using(PerlInterpreter *proto_perl, UV flags, param->stashes = newAV(); /* Setup array of objects to call clone on */ + /* Set tainting stuff before PerlIO_debug can possibly get called */ + PL_tainting = proto_perl->Itainting; + PL_taint_warn = proto_perl->Itaint_warn; + #ifdef PERLIO_LAYERS /* Clone PerlIO tables as soon as we can handle general xx_dup() */ PerlIO_clone(aTHX_ proto_perl, param); @@ -11494,8 +11498,6 @@ perl_clone_using(PerlInterpreter *proto_perl, UV flags, PL_fdpid = av_dup_inc(proto_perl->Ifdpid, param); /* internal state */ - PL_tainting = proto_perl->Itainting; - PL_taint_warn = proto_perl->Itaint_warn; PL_maxo = proto_perl->Imaxo; if (proto_perl->Iop_mask) PL_op_mask = SAVEPVN(proto_perl->Iop_mask, PL_maxo);