From: Thiemo Seufer Date: Mon, 19 Feb 2007 17:46:53 +0000 (+0000) Subject: * interp.c (sim_monitor): Flush stdout and stderr file descriptors X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=f8df4c7704d349e0622d471b2e0d2bfb86cd5b2f;p=binutils-gdb.git * interp.c (sim_monitor): Flush stdout and stderr file descriptors after each call to sim_io_write. --- diff --git a/sim/mips/ChangeLog b/sim/mips/ChangeLog index 632ae32880f..9ff5dbb0ddb 100644 --- a/sim/mips/ChangeLog +++ b/sim/mips/ChangeLog @@ -1,3 +1,9 @@ +2007-02-19 Thiemo Seufer + Nigel Stephens + + * interp.c (sim_monitor): Flush stdout and stderr file descriptors + after each call to sim_io_write. + 2007-02-19 Thiemo Seufer Nigel Stephens diff --git a/sim/mips/interp.c b/sim/mips/interp.c index 13cd26e2c55..51ad1de6fa3 100644 --- a/sim/mips/interp.c +++ b/sim/mips/interp.c @@ -1264,6 +1264,10 @@ sim_monitor (SIM_DESC sd, char *buf = zalloc (nr); sim_read (sd, A1, buf, nr); V0 = sim_io_write (sd, fd, buf, nr); + if (fd == 1) + sim_io_flush_stdout (sd); + else if (fd == 2) + sim_io_flush_stderr (sd); zfree (buf); break; }