Browse Source

* keep the tiny heap free blocks ordered by start address, instead of size.
Rationale: 1) TP7 compatibility, 2) easier debugging of heap corruption
problems

git-svn-id: trunk@28518 -

nickysn 11 years ago
parent
commit
03a838556f
1 changed files with 1 additions and 1 deletions
  1. 1 1
      rtl/inc/tinyheap.inc

+ 1 - 1
rtl/inc/tinyheap.inc

@@ -178,7 +178,7 @@
                   p := TinyHeapBlocks;
                   p := TinyHeapBlocks;
                   prev := nil;
                   prev := nil;
 
 
-                  while assigned(p) and (p^.Size < size) do
+                  while assigned(p) and (TTinyHeapPointerArithmeticType(p) < TTinyHeapPointerArithmeticType(b)) do
                     begin
                     begin
                       prev := p;
                       prev := p;
                       p := p^.Next;
                       p := p^.Next;