summaryrefslogtreecommitdiff
path: root/hv.c
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2010-11-25 13:53:28 +0000
committerNicholas Clark <nick@ccl4.org>2010-11-25 13:53:28 +0000
commita3179684398978e8bf4afba360eb728e4215d751 (patch)
treec40ed61c5b3f5d74e8abcffa0547e99d27aecdef /hv.c
parent2456140e9cfda88ed22ea1c7290a61234c84aea6 (diff)
downloadperl-a3179684398978e8bf4afba360eb728e4215d751.tar.gz
Use newSVpvs_flags() instead of sv_2mortal(newSVpvs())
And similarly for newSVpvn() for a known length.
Diffstat (limited to 'hv.c')
-rw-r--r--hv.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hv.c b/hv.c
index 18411d6a4f..a9fedb4bfc 100644
--- a/hv.c
+++ b/hv.c
@@ -3428,7 +3428,7 @@ Perl_store_cop_label(pTHX_ COP *const cop, const char *label, STRLEN len,
if (flags & ~(SVf_UTF8))
Perl_croak(aTHX_ "panic: store_cop_label illegal flag bits 0x%" UVxf,
(UV)flags);
- labelsv = sv_2mortal(newSVpvn(label, len));
+ labelsv = newSVpvn_flags(label, len, SVs_TEMP);
if (flags & SVf_UTF8)
SvUTF8_on(labelsv);
cop->cop_hints_hash