Forum > General

Debug - stack trace

(1/3) > >>

faber:
Can someone tell me where can I find some information (to learn) how to read stack trace (exception adresses with out line numbers) ?

Chronos:
http://wiki.lazarus.freepascal.org/Logging_exceptions

Not yet complete summary but it would be.

faber:
Wow, really nice!
Thanks for info

faber:
I've last question,
can I get map file with line info ? like:

  Stack trace:
  $00439E86
  $00439E33
  $004D47C4  TCONTROL__CLICK,  line 2251 of ./include/control.inc
  $0050391F  TBUTTONCONTROL__CLICK,  line 62 of ./include/buttoncontrol.inc
  $00503E46  TCUSTOMBUTTON__CLICK,  line 174 of ./include/buttons.inc
  $005043A1  TBUTTON__CLICK,  line 341 of ./include/buttons.inc
...

in other words how to find in what line of my files exception occurred ?

faber:
Ok, I can use gdb for that.

There is a mistake on this wiki page, that code:

--- Code: ---  for I := 0 to ExceptFrameCount - 1 do
    Report := Report + NewLine + BackTraceStrFunc(Frames);

--- End code ---

should look like:


--- Code: ---  for I := 0 to ExceptFrameCount - 1 do
    Report := Report + NewLine + BackTraceStrFunc(Frames[I]);

--- End code ---

Navigation

[0] Message Index

[#] Next page

Go to full version