summaryrefslogtreecommitdiff
path: root/malloc.c
diff options
context:
space:
mode:
authorGurusamy Sarathy <gsar@cpan.org>1998-11-29 16:08:03 +0000
committerGurusamy Sarathy <gsar@cpan.org>1998-11-29 16:08:03 +0000
commit2d8e6c8d50eaf50f663a5fd184404c73944226e0 (patch)
treee5592e6ebd4ebedeee8ebc8ddbb60cad5f477fc4 /malloc.c
parentb099ddc068b2498767e6f04ac167d9633b895ec4 (diff)
downloadperl-2d8e6c8d50eaf50f663a5fd184404c73944226e0.tar.gz
another threads reliability fix: serialize writes to thr->threadsv
avoid most uses of PL_na (which is much more inefficient than a simple local); update docs to suit; PL_na now being thr->Tna may be a minor compatibility issue for extensions--will require dTHR outside of XSUBs (those get automatic dTHR) p4raw-id: //depot/perl@2387
Diffstat (limited to 'malloc.c')
-rw-r--r--malloc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/malloc.c b/malloc.c
index add79bb218..d99b059d05 100644
--- a/malloc.c
+++ b/malloc.c
@@ -726,6 +726,7 @@ emergency_sbrk(MEM_SIZE size)
SV *sv;
char *pv;
int have = 0;
+ STRLEN n_a;
if (emergency_buffer_size) {
add_to_chain(emergency_buffer, emergency_buffer_size, 0);
@@ -741,7 +742,7 @@ emergency_sbrk(MEM_SIZE size)
return (char *)-1; /* Now die die die... */
}
/* Got it, now detach SvPV: */
- pv = SvPV(sv, PL_na);
+ pv = SvPV(sv, n_a);
/* Check alignment: */
if (((UV)(pv - sizeof(union overhead))) & ((1<<LOG_OF_MIN_ARENA) - 1)) {
PerlIO_puts(PerlIO_stderr(),"Bad alignment of $^M!\n");