GNU bug report logs - #10933
24.0.94; No output shown in *input/output* buffer of M-x gdb not working after first run

Previous Next

Package: emacs;

Reported by: Rolando Pereira <ei08150 <at> fe.up.pt>

Date: Sat, 3 Mar 2012 23:32:01 UTC

Severity: important

Found in version 24.0.94

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

Full log


Message #19 received at 10933-done <at> debbugs.gnu.org (full text, mbox):

From: Troels Nielsen <bn.troels <at> gmail.com>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: Rolando Pereira <ei08150 <at> fe.up.pt>, 10933-done <at> debbugs.gnu.org
Subject: Re: bug#10933: Acknowledgement (24.0.94; No output shown in
	*input/output* buffer of M-x gdb not working after first run)
Date: Fri, 23 Mar 2012 13:50:12 +0100
Stefan Monnier writes:
 > > I think this bug is due to gdb-mi creating a pty which it expects to
 > > remain open. When the process being debugged disconnects, emacs will
 > > receive an EIO-errno and (I believe mistakenly) send a SIGCHLD to
 > > itself, and stop listening to the pty.
 > 
 > > This patch fixes the problem for me.

 > Thanks, I don't understand what is special about gdb-mi that it's
 > the only one to trigger this problem, and I suspect there's a
 > slightly cleaner fix (as the above comment mentions, we only send
 > ourselves a SIGCHLD to work around problems we don't understand in
 > some undescribed situations, which may even be situations that
 > don't exist any more nowadays for all I know).

I think the problems mentioned in the comments are due to SIGCHLD
sometimes getting lost on certain unices, when two children or more
exit (or maybe generally when many signals are sent) simultaneously.

I believe (but may be mistaken :) ) that it is only relevant when
emacs itself is responsible for parenting the process. In this case
however gdb-mi is only creating a pty (using create_pty in process.c),
which gdb is instructed to connect the debugged process to. So gdb is
the parent and emacs should probably not care too much if the
debugged process dies.

Troels




This bug report was last modified 13 years and 146 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.