In the vanilla gdb interface, I can hit C-c to break the running program, insert breakpoints, etc., and then run continue to resume execution of the program being debugged. Is this possible with gud? C-c C-c in gud actually sends SIGKILL to the program, rather than breaking in gdb...
More info and repro
I'm actually trying to debug emacs (from a separate emacs+gud instance, of course) to try to get to the bottom of this guy. Here's what I'm doing:
$ cd path/to/emacs-24.5 # where I've built emacs with debugging symbols, etc $ ./src/emacs -Q M-x gdb Run gdb (like this): gdb -i=mi ./src/emacs run At this point I'd like to break the execution of the new emacs process so that I can poke around, set breakpoints, etc. My end game is to wait for the new emacs process to get into the bad state described in my bug report (sometimes takes days). That's when I really want to break execution of emacs and set the breakpoints.
SIGINTto the gdb process?gdbis running ingdb -i=mimode soSIGINTis probably handled differently.emacs, where you'll want to useC-c C-z, instead ofC-c C-c. My memory is fuzzy and it's a part I'm not very familiar with, but IIRC it's linked to the fact that under a tty Emacs treats SIGINT as an input key (corresponding toC-gmaybe?)