diff options
author | Nicholas Clark <nick@ccl4.org> | 2006-04-16 13:25:18 +0000 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2006-04-16 13:25:18 +0000 |
commit | aa0a69cb4bc6ac8103067b4dd5c2d09748f9d78d (patch) | |
tree | 914611769e5a881b792bfa2552c84d59d795e05a | |
parent | 2e90b4cd9b8959c8a9cede0cb14ef5338ec93d49 (diff) | |
download | perl-aa0a69cb4bc6ac8103067b4dd5c2d09748f9d78d.tar.gz |
Perl_do_vop can profitably use Perl_sv_usepvn_flags, as it has
allocated space for an initialised a trailing NUL.
p4raw-id: //depot/perl@27843
-rw-r--r-- | doop.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -1214,7 +1214,7 @@ Perl_do_vop(pTHX_ I32 optype, SV *sv, SV *left, SV *right) needlen = ((optype == OP_BIT_AND) ? len : (leftlen > rightlen ? leftlen : rightlen)); Newxz(dc, needlen + 1, char); - (void)sv_usepvn(sv, dc, needlen); + sv_usepvn_flags(sv, dc, needlen, SV_HAS_TRAILING_NUL); dc = SvPVX(sv); /* sv_usepvn() calls Renew() */ } SvCUR_set(sv, len); |