Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-devel / 2002-10

bug

1 message · 1 person ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Rimgaudas Laucius

Hi,

earlier i wrote about very strange error. I trayed to debug it and found that esi register is not initialized before it is used. It is visible in the attached picture.
Much more i insert missing asm line into program source and now it works fine:
procedure TGDB.LoadFile(p: PChar); stdcall;
var
  s: string;
begin
  {$ASMMODE intel}
  asm
     mov  esi, DWORD PTR [ebp+8];  // <---------missing code
  end;
  if fRunn then
     Reset;
  WriteLn(fRunn);  //<------now program does not crashes
  s:= p;
  LoadFile(s);
  StartTrace;
  fRunn:= true;
end;

I think this bug origin is interface used in the class. Because i noticed similar problem with interfaces and wrote about it ealier.

Reply by email