summaryrefslogtreecommitdiff
path: root/sv.c
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2006-04-16 21:44:59 +0000
committerNicholas Clark <nick@ccl4.org>2006-04-16 21:44:59 +0000
commit8f01dc65ffe0fac5309bf561048e6ae93442a218 (patch)
tree9f87d6dffefd0a1a32f7a6ae2aa39d2867939866 /sv.c
parent6e11062851163c9273b977b9a485fd8cd91aaeff (diff)
downloadperl-8f01dc65ffe0fac5309bf561048e6ae93442a218.tar.gz
Fix bug introduced with change 27841. (len + 1, not just len).
p4raw-id: //depot/perl@27852
Diffstat (limited to 'sv.c')
-rw-r--r--sv.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sv.c b/sv.c
index 308ecf8a8c..429794fc98 100644
--- a/sv.c
+++ b/sv.c
@@ -3924,7 +3924,7 @@ Perl_sv_usepvn_flags(pTHX_ SV *sv, char *ptr, STRLEN len, U32 flags)
assert(ptr[len] == '\0');
allocate = (flags & SV_HAS_TRAILING_NUL)
- ? len : PERL_STRLEN_ROUNDUP(len + 1);
+ ? len + 1: PERL_STRLEN_ROUNDUP(len + 1);
#ifdef DEBUGGING
{
/* Force a move to shake out bugs in callers. */