Hacker News new | ask | show | jobs
by TheYumasi 1340 days ago
The TUI is from gdb.[1] Nothing from GDB is compiled in your binary. My guess (might be wrong!) is that the ShowCrashReports() call added in your program's main function sets up some signal handlers, so that in case of segfaults it starts GDB in a separate process and attaches it to your crashing process.

[1]: https://sourceware.org/gdb/onlinedocs/gdb/TUI.html

2 comments

Which you have to admit is quite simple but brilliant.
when did they add this?!?