diff options
author | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2008-04-15 15:54:31 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2008-04-15 15:54:31 +0000 |
commit | cc93af5fbd42046d3d6e19c3655b76edf6980b42 (patch) | |
tree | 5fba21b2d36d66f6d2cc91f21bc15535173941d2 /op.c | |
parent | e780cd349007c0f64ff926c118b4b7ef8d8f6df5 (diff) | |
download | perl-cc93af5fbd42046d3d6e19c3655b76edf6980b42.tar.gz |
Call cop_free on nullified cops too
(this is a followup to 33687)
p4raw-id: //depot/perl@33695
Diffstat (limited to 'op.c')
-rw-r--r-- | op.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -502,7 +502,10 @@ Perl_op_free(pTHX_ OP *o) /* COP* is not cleared by op_clear() so that we may track line * numbers etc even after null() */ - if (type == OP_NEXTSTATE || type == OP_DBSTATE) { + if (type == OP_NEXTSTATE || type == OP_DBSTATE + || (type == OP_NULL /* the COP might have been null'ed */ + && ((OPCODE)o->op_targ == OP_NEXTSTATE + || (OPCODE)o->op_targ == OP_DBSTATE))) { cop_free((COP*)o); } |