memcheck: raising RunError 204 on error in linked list

git-svn-id: trunk@12234 -
This commit is contained in:
mattias 2007-09-29 10:21:43 +00:00
parent 62639b92b8
commit c8e3c47a30
2 changed files with 5 additions and 3 deletions

View File

@ -12,7 +12,7 @@ interface
check by CRC value if not changed after release check by CRC value if not changed after release
WARNING this needs extremely much memory (PM) } WARNING this needs extremely much memory (PM) }
{ $DEFINE Extra} {$DEFINE Extra}
{$inline off}// inline off for stack traces {$inline off}// inline off for stack traces
@ -362,11 +362,13 @@ begin
is_in_getmem_list:=true; is_in_getmem_list:=true;
pp:=pp^.previous; pp:=pp^.previous;
inc(i); inc(i);
if i>loc_info^.getmem_cnt-loc_info^.freemem_cnt then if i>loc_info^.getmem_cnt-loc_info^.freemem_cnt then begin
if useownfile then if useownfile then
writeln(ownfile,'error in linked list of heap_mem_info') writeln(ownfile,'error in linked list of heap_mem_info')
else else
writeln(stderr,'error in linked list of heap_mem_info'); writeln(stderr,'error in linked list of heap_mem_info');
RunError(204);
end;
end; end;
end; end;

View File

@ -40,7 +40,7 @@ program Lazarus;
{$R lazarus.rc} {$R lazarus.rc}
{$ENDIF} {$ENDIF}
{off $DEFINE IDE_MEM_CHECK} {$DEFINE IDE_MEM_CHECK}
uses uses
//cmem, //cmem,