Retract #17380, the refcnt tweak was misplaced (re_dup is used
Jarkko Hietaniemi [Sun, 30 Jun 2002 02:45:58 +0000 (02:45 +0000)]
when creation of new threads needs to duplicate the re struct)

p4raw-id: //depot/perl@17383

sv.c

diff --git a/sv.c b/sv.c
index 270c58d..fa629ae 100644 (file)
--- a/sv.c
+++ b/sv.c
@@ -8612,7 +8612,7 @@ Perl_re_dup(pTHX_ REGEXP *r, CLONE_PARAMS *param)
     Copy(r->offsets, ret->offsets, 2*len+1, U32);
 
     ret->precomp        = SAVEPV(r->precomp);
-    ret->refcnt         = 1;
+    ret->refcnt         = r->refcnt;
     ret->minlen         = r->minlen;
     ret->prelen         = r->prelen;
     ret->nparens        = r->nparens;