when cloning PL_regex_pad, copy SVf_BREAK flag too
Dave Mitchell [Mon, 15 Jan 2007 18:19:20 +0000 (18:19 +0000)]
p4raw-id: //depot/perl@29837

sv.c

diff --git a/sv.c b/sv.c
index 33cdb52..bfc9ee7 100644 (file)
--- a/sv.c
+++ b/sv.c
@@ -11025,6 +11025,8 @@ perl_clone_using(PerlInterpreter *proto_perl, UV flags,
                        newSViv(PTR2IV(CALLREGDUPE(
                                INT2PTR(REGEXP *, SvIVX(regex)), param))))
                ;
+           if (SvFLAGS(regex) & SVf_BREAK)
+               SvFLAGS(sv) |= SVf_BREAK; /* unrefcnted PL_curpm */
            av_push(PL_regex_padav, sv);
        }
     }