public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug gdb/15791] New: Without TTY, the order of output in stdout and stderr is undetermined
@ 2013-07-26 13:22 qiyao at gcc dot gnu.org
  2013-07-26 16:15 ` [Bug gdb/15791] " peter.schauer at mytum dot de
  2013-07-27  0:21 ` qiyao at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: qiyao at gcc dot gnu.org @ 2013-07-26 13:22 UTC (permalink / raw)
  To: gdb-prs

http://sourceware.org/bugzilla/show_bug.cgi?id=15791

            Bug ID: 15791
           Summary: Without TTY, the order of output in stdout and stderr
                    is undetermined
           Product: gdb
           Version: HEAD
            Status: NEW
          Severity: normal
          Priority: P2
         Component: gdb
          Assignee: unassigned at sourceware dot org
          Reporter: qiyao at gcc dot gnu.org

When I ssh to localhost as below, there is no TTY.

$ ssh 127.0.0.1 /home/yao/Source/gnu/gdb/build-git/x86/gdb/gdb
GNU gdb (GDB) 7.6.50.20130724-cvs
Copyright (C) 2013 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i686-pc-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word".

(gdb) set width 0
(gdb) set height 0
(gdb) delete breakpoint 0
warning: bad breakpoint number at or near '0'(gdb) 
delete breakpoint 0
warning: bad breakpoint number at or near '0'
(gdb) quit

As we can see, the order of warning and gdb prompt varies from run to run.  I
can reproduce the problem when I ssh to cygwin and start a mingw32 native GDB. 
This problem causes some fails in remote host testing.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


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

* [Bug gdb/15791] Without TTY, the order of output in stdout and stderr is undetermined
  2013-07-26 13:22 [Bug gdb/15791] New: Without TTY, the order of output in stdout and stderr is undetermined qiyao at gcc dot gnu.org
@ 2013-07-26 16:15 ` peter.schauer at mytum dot de
  2013-07-27  0:21 ` qiyao at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: peter.schauer at mytum dot de @ 2013-07-26 16:15 UTC (permalink / raw)
  To: gdb-prs

http://sourceware.org/bugzilla/show_bug.cgi?id=15791

Peter Schauer <peter.schauer at mytum dot de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |peter.schauer at mytum dot de

--- Comment #1 from Peter Schauer <peter.schauer at mytum dot de> ---
This is a general problem with all native windows console applications
running under a cygwin shell with cygwin ttys.
I am not sure if GDB should work around this general problem.

A solution is provided by
https://github.com/rprichard/winpty
https://github.com/downloads/rprichard/winpty/winpty-0.1.1-cygwin.zip

If you install the package und then run
console /home/yao/Source/gnu/gdb/build-git/x86/gdb/gdb
stdout and stderr will work as expected.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


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

* [Bug gdb/15791] Without TTY, the order of output in stdout and stderr is undetermined
  2013-07-26 13:22 [Bug gdb/15791] New: Without TTY, the order of output in stdout and stderr is undetermined qiyao at gcc dot gnu.org
  2013-07-26 16:15 ` [Bug gdb/15791] " peter.schauer at mytum dot de
@ 2013-07-27  0:21 ` qiyao at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: qiyao at gcc dot gnu.org @ 2013-07-27  0:21 UTC (permalink / raw)
  To: gdb-prs

http://sourceware.org/bugzilla/show_bug.cgi?id=15791

--- Comment #2 from Yao Qi <qiyao at gcc dot gnu.org> ---
Thanks for the pointer.  This problem also occurs on linux as well, so I am
wondering probably there is something we can improve in GDB.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


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

end of thread, other threads:[~2013-07-27  0:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-26 13:22 [Bug gdb/15791] New: Without TTY, the order of output in stdout and stderr is undetermined qiyao at gcc dot gnu.org
2013-07-26 16:15 ` [Bug gdb/15791] " peter.schauer at mytum dot de
2013-07-27  0:21 ` qiyao at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).