Ver código fonte

* use sizeof(CORE_ADDR) instead of sizeof(pointer) for finding the parameters
on the stack in GetFPCBreakParameters

git-svn-id: trunk@30117 -

nickysn 10 anos atrás
pai
commit
a32b335832
1 arquivos alterados com 3 adições e 3 exclusões
  1. 3 3
      ide/fpdebug.pas

+ 3 - 3
ide/fpdebug.pas

@@ -1290,9 +1290,9 @@ end;
 function TDebugController.GetFPCBreakErrorParameters(var ExitCode: LongInt; var ExitAddr, ExitFrame: CORE_ADDR): Boolean;
 function TDebugController.GetFPCBreakErrorParameters(var ExitCode: LongInt; var ExitAddr, ExitFrame: CORE_ADDR): Boolean;
 const
 const
   { try to find the parameters }
   { try to find the parameters }
-  FirstArgOffset = -sizeof(pointer);
-  SecondArgOffset = 2*-sizeof(pointer);
-  ThirdArgOffset = 3*-sizeof(pointer);
+  FirstArgOffset = -sizeof(CORE_ADDR);
+  SecondArgOffset = 2*-sizeof(CORE_ADDR);
+  ThirdArgOffset = 3*-sizeof(CORE_ADDR);
 begin
 begin
   // Procedure HandleErrorAddrFrame (Errno : longint;addr : CodePointer; frame : Pointer);
   // Procedure HandleErrorAddrFrame (Errno : longint;addr : CodePointer; frame : Pointer);
   //  [public,alias:'FPC_BREAK_ERROR']; {$ifdef cpui386} register; {$endif}
   //  [public,alias:'FPC_BREAK_ERROR']; {$ifdef cpui386} register; {$endif}