diff options
author | David Mitchell <davem@iabyn.com> | 2011-02-17 14:50:04 +0000 |
---|---|---|
committer | David Mitchell <davem@iabyn.com> | 2011-02-18 11:25:24 +0000 |
commit | 9274aefd575ecb452e8b3e33659780c198ca43ab (patch) | |
tree | dadc562b6515d875e50a8fc8e94411c1f290bb5f /pp_hot.c | |
parent | 5e79dfb9cd4496df40e823bec270c4bcde98db07 (diff) | |
download | perl-9274aefd575ecb452e8b3e33659780c198ca43ab.tar.gz |
taint REGEX SVs as well as refs to them
Now that REGEX is actually a first-class SV type, we can taint
the regex SV directly, as well as the RV pointing to it.
This means that this now taints:
$rr = qr/$tainted/;
$r = $$r;
/$r/;
Diffstat (limited to 'pp_hot.c')
-rw-r--r-- | pp_hot.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -1235,8 +1235,10 @@ PP(pp_qr) (void)sv_bless(rv, stash); } - if (RX_EXTFLAGS(rx) & RXf_TAINTED) + if (RX_EXTFLAGS(rx) & RXf_TAINTED) { SvTAINTED_on(rv); + SvTAINTED_on(SvRV(rv)); + } XPUSHs(rv); RETURN; } |