summaryrefslogtreecommitdiff
path: root/av.c
diff options
context:
space:
mode:
authorMalcolm Beattie <mbeattie@sable.ox.ac.uk>1997-10-03 15:17:39 +0000
committerMalcolm Beattie <mbeattie@sable.ox.ac.uk>1997-10-03 15:17:39 +0000
commitfba3b22e783d72569126ff6fe76f3cb6cd1f043b (patch)
treea06e4145c0f1a902cb2070e0aaa8729cebfe5b6e /av.c
parentc23142e2edb5ee317dcd6cd29300b6f2196357db (diff)
downloadperl-fba3b22e783d72569126ff6fe76f3cb6cd1f043b.tar.gz
Fixed sv_mutex locking for new_SV, del_SV and nice_chunks.
p4raw-id: //depot/perl@103
Diffstat (limited to 'av.c')
-rw-r--r--av.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/av.c b/av.c
index b9382a8d9c..86232216ec 100644
--- a/av.c
+++ b/av.c
@@ -90,10 +90,8 @@ I32 key;
newmax = tmp - 1;
New(2,ary, newmax+1, SV*);
Copy(AvALLOC(av), ary, AvMAX(av)+1, SV*);
- if (AvMAX(av) > 64 && !nice_chunk) {
- nice_chunk = (char*)AvALLOC(av);
- nice_chunk_size = (AvMAX(av) + 1) * sizeof(SV*);
- }
+ if (AvMAX(av) > 64)
+ offer_nice_chunk(AvALLOC(av), (AvMAX(av)+1) * sizeof(SV*));
else
Safefree(AvALLOC(av));
AvALLOC(av) = ary;