This is a live mirror of the Perl 5 development currently hosted at
https://github.com/perl/perl5
https://perl5.git.perl.org
/
perl5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f25eda1
)
In Perl_sv_grow(), no need to do PERL_STRLEN_ROUNDUP() if we have
author
Nicholas Clark
<nick@ccl4.org>
Wed, 2 Apr 2008 21:03:33 +0000
(21:03 +0000)
committer
Nicholas Clark
<nick@ccl4.org>
Wed, 2 Apr 2008 21:03:33 +0000
(21:03 +0000)
malloc_size() to get the true allocated space, as PERL_STRLEN_ROUNDUP()
might actually bump the request across an allocation size boundary.
p4raw-id: //depot/perl@33632
sv.c
patch
|
blob
|
blame
|
history
diff --git
a/sv.c
b/sv.c
index
03925a4
..
96ef7c8
100644
(file)
--- a/
sv.c
+++ b/
sv.c
@@
-1492,7
+1492,7
@@
Perl_sv_grow(pTHX_ register SV *const sv, register STRLEN newlen)
s = SvPVX_mutable(sv);
if (newlen > SvLEN(sv)) { /* need more room? */
-#ifndef
MYMALLOC
+#ifndef
Perl_safesysmalloc_size
newlen = PERL_STRLEN_ROUNDUP(newlen);
#endif
if (SvLEN(sv) && s) {