summaryrefslogtreecommitdiff
path: root/sv.c
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2006-04-13 10:46:32 +0000
committerNicholas Clark <nick@ccl4.org>2006-04-13 10:46:32 +0000
commit8fbc55279aa56e88684b31864922ee4cfa976b1a (patch)
tree05a200dbb68459e9925b649fff840f1d3c27e2be /sv.c
parent8ee4cf2435c265a68309f8b98520e063bbdc8e42 (diff)
downloadperl-8fbc55279aa56e88684b31864922ee4cfa976b1a.tar.gz
Add SAVEt_COP_WARNINGS to ss_dup.
p4raw-id: //depot/perl@27785
Diffstat (limited to 'sv.c')
-rw-r--r--sv.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/sv.c b/sv.c
index 3b9dfb8c04..c9debc63cc 100644
--- a/sv.c
+++ b/sv.c
@@ -10681,6 +10681,21 @@ Perl_ss_dup(pTHX_ PerlInterpreter *proto_perl, CLONE_PARAMS* param)
#endif
break;
}
+ case SAVEt_COP_WARNINGS:
+ {
+ void *optr = POPPTR(ss,ix);
+ TOPPTR(nss,ix) = ptr = any_dup(optr, proto_perl);
+ if (ptr != optr) {
+ /* We duped something in the interpreter structure. */
+ ptr = POPPTR(ss,ix);
+ TOPPTR(nss,ix) = DUP_WARNINGS((STRLEN*)ptr);
+ } else {
+ /* I don't think that this happens, but it would mean that
+ we (didn't) dup something shared. */
+ ptr = POPPTR(ss,ix);
+ TOPPTR(nss,ix) = ptr;
+ }
+ }
default:
Perl_croak(aTHX_ "panic: ss_dup inconsistency (%"IVdf")", (IV) i);
}