Sign in Join

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

Mailing lists / lazarus / 2025-07

access violation

3 messages · 3 people ·

Reply by email Subscribe to this list Your subscription

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

Martin Frb
to duilio foschi
duilio foschi wrote 7 lines
when exiting my application, an exception is raised: https://ibb.co/vCKVJssV Is there a way to go from the problematic hex address to the unit and line no?

Depends...

It looks like this is caught be the debugger. If you press ok, then the IDE (the debugger) should either
- go to a line in the source (in some cases may be the function calling the buggy code)
- open the assemble window

So then it depends which of those 2 happens?

In either case, you can go to menu:
View > Debug Windows > CallStack

And in the callstack, you can check if you find any of your code in the list.

E.g. sometimes you do something like
 ? ObjectThatAlreadyWasDestroyed.Destroy;

Then the error is somewhere in Destroy. But the code in destroy will not help you (and it wont be show to you, unless you did your own FPC build).

But the callstack will contain the line function that does
 ? ObjectThatAlreadyWasDestroyed.Destroy;

Of course it may be any other type of error....

-----------
If the callstack does not give any name functions and not give any entries with line numbers then check in "Project Options" > Debugging.

Do you have "generate info for debugger" enabled?
And is "type of debug info" Dwarf, or Dwarf with sets, or Dwarf 3? (On Windows you want Dwarf 3 / but line numbers will work with any of them)

What does the callstack show?

Reply by email