* after r34939, it was not taken care of the extra storage needed for the size field, fixed, should fix #32875

git-svn-id: trunk@37883 -
This commit is contained in:
florian 2017-12-30 16:38:13 +00:00
parent acf6fde3cf
commit d315d3cc96

View File

@ -49,10 +49,10 @@ Unit heapmgr;
p, prev: PHeapBlock;
AllocSize, RestSize: ptruint;
begin
if size<MinBlock then
if size+sizeof(PtrUInt)<MinBlock then
AllocSize := MinBlock
else
AllocSize := align(size, sizeof(pointer));
AllocSize := align(size+sizeof(PtrUInt), sizeof(pointer));
p := Blocks;
prev := nil;