GNU bug report logs - #12180
Fwd: bug#12163: 24.1; Can not input anything or showing none output when debugging c/c++ application.

Previous Next

Package: emacs;

Reported by: qq510371827 <qq510371827 <at> gmail.com>

Date: Sat, 11 Aug 2012 15:21:01 UTC

Severity: normal

Tags: moreinfo

Merged with 12163

Found in version 24.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: qq510371827 <qq510371827 <at> gmail.com>
To: eliz <at> gnu.org, 12180 <at> debbugs.gnu.org
Subject: bug#12180: bug#12163: 24.1; Can not input anything or showing none output when debugging c/c++ application.
Date: Mon, 13 Aug 2012 22:00:33 +0800
[Message part 1 (text/plain, inline)]
' set new-console on ' command works for me. I have tried eclipse cdt  and
it also has the same problem as emacs 24.1 on windows with mingw.
Strangely, why emacs 23.4 just works?
2012/8/13 Eli Zaretskii <eliz <at> gnu.org>

> > From: qq510371827 <qq510371827 <at> gmail.com>
> > Date: Sun, 12 Aug 2012 09:32:14 +0800
> > Cc: 12180 <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org
> >
> > Yes,I have tried that.Both GUI session and TTY session work very well.
>
> I guess it's a matter of timing, then: there's a certain race
> condition between Emacs that crams commands into GDB and the debuggee
> that reads from stdin.  If the latter comes after Emacs already sent
> all the commands, then the program will work correctly.  But that's a
> guess; I hope someone knowledgeable about GUD, comint, and gdb-mi will
> chime in.  Nick? somebody?
>
> Anyway, I found a work-around for this problem.  After entering GDB,
> and before running your program, type this command at GDB prompt:
>
>   (gdb) set new-console on
>
> This will cause GDB to create a separate console window for the input
> and output of your program, when you run it, and you can then
> communicate with your program without mixing its I/O with that of GDB.
> Just be sure to put a breakpoint at the 'exit' call or at the last
> line of your 'main' function, if you want to look at the program
> output.  If you don't do that, the console will be automatically
> closed when your program exits.
>
[Message part 2 (text/html, inline)]

This bug report was last modified 3 years and 80 days ago.

Previous Next


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