GDB will catch SIGSEGV before the application executes.
What you described in the comment on Logan does not make sense.
I suspect that what is actually happening is that the application creates a new process and receives only SIGSEGV in this other process, and not the one to which you bound GDB.
The following commands may be useful if my assumption is correct:
(gdb) catch fork (gdb) catch vfork (gdb) set follow-fork-mode child
You can also edit and expand your question:
- How do you know if there is
SIGSEGV for starters? - Posting a log of your interactions with
GDB can also be helpful.
Employed Russian
source share