Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [PATCH] Target stderr not displayed thru MI
@ 2005-11-30  2:47 Denis PILAT
  2005-11-30 13:51 ` Jim Blandy
  0 siblings, 1 reply; 14+ messages in thread
From: Denis PILAT @ 2005-11-30  2:47 UTC (permalink / raw)
  To: gdb-patches; +Cc: Serge CHATROUX

[-- Attachment #1: Type: text/plain, Size: 523 bytes --]

Hi all,

When debugging a program thru Eclipse or any front end using MI,
the stderr of the debugged program is lost.

This problem occures only on remote targets since native ones don't
use MI stream for output.

In the file gdb/mi/mi-interp.c, the 'mi_interpreter_resume' function
redirects the gdb stream into MI streams. All streams are redirected
except gdb_stdtargerr.

The attached patch (from a ST colleague) redirects target error output
on the unique MI target output stream.

Do you have any comment ?

Denis




[-- Attachment #2: mi-interp.patch --]
[-- Type: text/plain, Size: 594 bytes --]

2005-11-20  Serge Chatroux  <serge.chatroux@st.com>

	* mi-interp.c (mi_interpreter_resume): Route target error
	through the MI.


Index: mi-interp.c
===================================================================
--- mi-interp.c	(revision 245)
+++ mi-interp.c	(working copy)
@@ -119,6 +119,8 @@
   gdb_stdlog = mi->log;
   /* Route target output through the MI. */
   gdb_stdtarg = mi->targ;
+  /* Route target error through the MI as well. */
+  gdb_stdtargerr = mi->targ;
 
   /* Replace all the hooks that we know about.  There really needs to
      be a better way of doing this... */

^ permalink raw reply	[flat|nested] 14+ messages in thread
* Re:[PATCH] Target stderr not displayed thru MI
@ 2005-11-30 14:15 Nick Roberts
  2005-11-30 18:57 ` [PATCH] " Denis PILAT
  0 siblings, 1 reply; 14+ messages in thread
From: Nick Roberts @ 2005-11-30 14:15 UTC (permalink / raw)
  To: Denis PILAT; +Cc: gdb-patches


> +  /* Route target error through the MI as well. */
> +  gdb_stdtargerr = mi->targ;

I know nothing about remote debugging but shouldn't error output go to
mi->err so that you can distinguish it from target output?

Nick


^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2005-12-05 14:40 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-11-30  2:47 [PATCH] Target stderr not displayed thru MI Denis PILAT
2005-11-30 13:51 ` Jim Blandy
2005-11-30 14:15 Nick Roberts
2005-11-30 18:57 ` [PATCH] " Denis PILAT
2005-11-30 19:03   ` Bob Rossi
2005-11-30 19:55     ` Daniel Jacobowitz
     [not found]   ` <17294.2894.345752.773239@kahikatea.snap.net.nz>
2005-12-01 13:57     ` Denis PILAT
2005-12-01 14:06       ` Bob Rossi
2005-12-01 14:32         ` Daniel Jacobowitz
2005-12-01 16:20           ` Denis PILAT
2005-12-01 22:49           ` Nick Roberts
2005-12-02  1:26             ` Jim Blandy
2005-12-05 20:50             ` Denis PILAT
2005-12-06  6:09               ` Nick Roberts
2005-12-06 10:49                 ` Daniel Jacobowitz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox