all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Nick Roberts <nick@nick.uklinux.net>
Cc: emacs-devel@gnu.org
Subject: gdbui hang
Date: Mon, 10 May 2004 18:41:03 +0100	[thread overview]
Message-ID: <16543.48815.692499.486290@nick.uklinux.net> (raw)
In-Reply-To: <buosme899jk.fsf@mcspd15.ucom.lsi.nec.co.jp>

 > [A related problem is that if I kill the *gud-foo* buffer to try and
 > recover from the hang, and then start another gdb process, it will often
 > fail to work, saying `selecting deleted buffer' in a command I give.  In
 > general it's a good idea to recover gracefully if a buffer is deleted;
 > the gdb mode probably shouldn't be keeping any session state outside of
 > the gdb buffer itself -- i.e., try to make any state variables
 > buffer-local in the gdb session buffer.]

This is because kill-buffer sends SIGHUP to the associated process. If GDB is
expecting input (as in the case you describe) then the process is immune to
SIGHUP and doesn't get killed.  Try this, even with the old GUD, type
list-buffers and you get something like:


Proc         Status   Buffer         Tty         Command
----         ------   ------         ---         -------
gud-myprog   run      (Killed)	     /dev/pts/4	 gdb -fullname /home/nick/myprog

Since the process is not killed, gud-sentinel doesn't get called and, in the
case of gdb-ui, the associated buffers stay there. To run gdb again requires
that these buffers (partial-output, breakpoints etc) are deleted first. 
"kill -9" will kill the GDB process but leave the inferior process.

Its messy, I agree, but I don't have an answer to this one. 

Does anybody else have a solution?

Nick

  parent reply	other threads:[~2004-05-10 17:41 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-05-10  4:43 gdbui hang Miles Bader
2004-05-10  6:22 ` Kim F. Storm
2004-05-10 17:30 ` Nick Roberts
2004-05-10 18:16   ` Stefan Monnier
2004-05-10 18:42     ` Nick Roberts
2004-05-11 12:23       ` Richard Stallman
2004-05-11 12:49       ` Miles Bader
2004-05-11 20:25         ` Nick Roberts
2004-05-11 21:08           ` Miles Bader
2004-05-11 21:27             ` Nick Roberts
2004-05-11 21:40             ` Stefan Monnier
2004-05-10 17:41 ` Nick Roberts [this message]
2004-05-10 19:09   ` Stefan Monnier
2004-05-11 21:07     ` Nick Roberts
2004-05-11 21:37       ` Stefan Monnier
2004-05-11 22:43         ` Nick Roberts
2004-05-11 23:23           ` Stefan Monnier
2004-05-12 12:40             ` Kim F. Storm
2004-05-12 14:59               ` Stefan Monnier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=16543.48815.692499.486290@nick.uklinux.net \
    --to=nick@nick.uklinux.net \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.