In perl.git, the branch blead has been updated <http://perl5.git.perl.org/perl.git/commitdiff/b7613b8a45c70113cb7f32d0bcfc9a03889ae272?hp=6610358143bf27b3aa51a6d6d17d81fe85d7dc31>
- Log ----------------------------------------------------------------- commit b7613b8a45c70113cb7f32d0bcfc9a03889ae272 Author: David Mitchell <[email protected]> Date: Thu Feb 26 12:59:16 2015 +0000 fix op leak caused by OP_MULTIDEREF [perl #123922] When converting a subtree like aelem | rv2av | rv2sv - const | gv into ex-aelem | multideref | ex-gv it was freeing the excised subtree, but failed to free the index expression (the const in this case). ----------------------------------------------------------------------- Summary of changes: op.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/op.c b/op.c index 2a76ae4..fdfac22 100644 --- a/op.c +++ b/op.c @@ -12777,7 +12777,9 @@ S_maybe_multideref(pTHX_ OP *start, OP *orig_o, UV orig_action, U8 hints) /* excise and free the original tree, and replace with * the multideref op */ - op_free(op_sibling_splice(top_op, NULL, -1, mderef)); + p = op_sibling_splice(top_op, NULL, -1, mderef); + for(; p; p = OpSIBLING(p)) + op_free(p); op_null(top_op); } else { -- Perl5 Master Repository
