diff options
author | Christopher Faylor <me@cgf.cx> | 2012-03-04 01:35:30 +0400 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2012-03-04 01:35:30 +0400 |
commit | bd7c945953b295f263978bb6a7747d2d1b728660 (patch) | |
tree | 4dba00d30aba6f97866ccd21aa40e1e4ac7962f6 /winsup/cygwin/fhandler_termios.cc | |
parent | 56bed670461db0bd7ccbb4315b7b6b0c4e418dab (diff) |
* fhandler_console.cc (fhandler_console::dup): Only set ctty when we haven't
specifically called setsid.
* fhandler_tty.cc (fhandler_pty_slave::dup): Ditto. Also add comment
documenting research into rxvt problem.
* fhandler_termios.cc (fhandler_termios::tcsetpgrp): Don't check specifically
for myself->ctty == -1. Test for > 0 as that is the correct test.
(fhandler_termios::sigflush): Ditto.
Diffstat (limited to 'winsup/cygwin/fhandler_termios.cc')
-rw-r--r-- | winsup/cygwin/fhandler_termios.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/winsup/cygwin/fhandler_termios.cc b/winsup/cygwin/fhandler_termios.cc index 36017dc63..70fb12877 100644 --- a/winsup/cygwin/fhandler_termios.cc +++ b/winsup/cygwin/fhandler_termios.cc @@ -99,7 +99,7 @@ fhandler_termios::tcsetpgrp (const pid_t pgid) int fhandler_termios::tcgetpgrp () { - if (myself->ctty != -1 && myself->ctty == tc ()->ntty) + if (myself->ctty > 0 && myself->ctty == tc ()->ntty) return tc ()->pgid; set_errno (ENOTTY); return -1; @@ -404,7 +404,7 @@ fhandler_termios::sigflush () pid_t fhandler_termios::tcgetsid () { - if (myself->ctty != -1 && myself->ctty == tc ()->ntty) + if (myself->ctty > 0 && myself->ctty == tc ()->ntty) return tc ()->getsid (); set_errno (ENOTTY); return -1; |