mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-16 12:19:18 +02:00
+ reverted to previous heap
This commit is contained in:
parent
eb5bc7aff7
commit
d3d9e234bd
@ -532,8 +532,7 @@ var
|
|||||||
proc : heaperrorproc;
|
proc : heaperrorproc;
|
||||||
last,hp : pfreerecord;
|
last,hp : pfreerecord;
|
||||||
again : boolean;
|
again : boolean;
|
||||||
s,sizeleft,hpsize : longint;
|
s,hpsize : longint;
|
||||||
pp : pointer;
|
|
||||||
{$IfDef CHECKHEAP}
|
{$IfDef CHECKHEAP}
|
||||||
i,bp,orsize : longint;
|
i,bp,orsize : longint;
|
||||||
label
|
label
|
||||||
@ -589,33 +588,6 @@ begin
|
|||||||
{$else CHECKHEAP}
|
{$else CHECKHEAP}
|
||||||
exit;
|
exit;
|
||||||
{$endif CHECKHEAP}
|
{$endif CHECKHEAP}
|
||||||
end
|
|
||||||
else
|
|
||||||
begin
|
|
||||||
inc(s);
|
|
||||||
while s<=maxblock do
|
|
||||||
begin
|
|
||||||
p:=blocks^[s];
|
|
||||||
if assigned(p) then
|
|
||||||
begin
|
|
||||||
blocks^[s]:=pointer(p^);
|
|
||||||
dec(nblocks^[s]);
|
|
||||||
sizeleft:=s-(size shr 3);
|
|
||||||
|
|
||||||
// reinsert the rest of the block
|
|
||||||
pp:=p+size;
|
|
||||||
ppointer(pp)^:=blocks^[sizeleft];
|
|
||||||
blocks^[sizeleft]:=pp;
|
|
||||||
inc(nblocks^[sizeleft]);
|
|
||||||
{$ifdef CHECKHEAP}
|
|
||||||
goto check_new;
|
|
||||||
{$else CHECKHEAP}
|
|
||||||
exit;
|
|
||||||
{$endif CHECKHEAP}
|
|
||||||
|
|
||||||
end;
|
|
||||||
inc(s);
|
|
||||||
end;
|
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
@ -1126,8 +1098,8 @@ end;
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.12 1999-08-20 10:31:17 michael
|
Revision 1.13 1999-08-20 13:26:20 michael
|
||||||
+ Patch for heap allocation from Florian
|
+ reverted to previous heap
|
||||||
|
|
||||||
Revision 1.11 1999/05/31 20:36:34 peter
|
Revision 1.11 1999/05/31 20:36:34 peter
|
||||||
* growing is now 256k or 1mb
|
* growing is now 256k or 1mb
|
||||||
|
Loading…
Reference in New Issue
Block a user