libSegFault and just in time debugging

Daniel Jacobowitz drow@false.org
Fri Jun 29 19:15:00 GMT 2007


On Fri, Jun 29, 2007 at 12:10:32PM -0700, Michael Snyder wrote:
> What if, instead of doing that, libSegFault (or another similar library)
> were to open a socket to a daemon and say "I caught a crash -- what
> do you want me to do?".  And then wait for a reply.  All that can be
> done with async-signal-safe function calls.

It's a brilliant idea.  Ubuntu did it :-)  It uses the Linux kernel's
core handling support, and is called apport.

  https://wiki.ubuntu.com/Apport

You'll notice a bit of a way down that there's GDB output; in this
case it comes from a core dump, but I'm pretty sure the same kernel
hooks can be used to take control before the core is dumped.  I'd have
to check.

-- 
Daniel Jacobowitz
CodeSourcery



More information about the Gdb mailing list