summaryrefslogtreecommitdiff
path: root/hurd
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>1994-09-30 21:12:14 +0000
committerRoland McGrath <roland@gnu.org>1994-09-30 21:12:14 +0000
commit8deefb609900b9007a72c9a62561a9485ea3a36d (patch)
tree1706a9e0cab0c9ebec402c0ec75c87afb94de784 /hurd
parent52a7a059135b7e8bd663aee74c2b364f7437c6bb (diff)
(_hurd_port2fd): Install normal port in D->port cell, and ctty-special port
in the D->ctty cell, not the reverse.
Diffstat (limited to 'hurd')
-rw-r--r--hurd/port2fd.c10
1 files changed, 1 insertions, 9 deletions
diff --git a/hurd/port2fd.c b/hurd/port2fd.c
index ad8576b5e2..cad89e770f 100644
--- a/hurd/port2fd.c
+++ b/hurd/port2fd.c
@@ -55,15 +55,7 @@ _hurd_port2fd (struct hurd_fd *d, io_t port, int flags)
}
}
- if (is_ctty && ! __term_open_ctty (port, _hurd_pid, _hurd_pgrp, &ctty))
- {
- /* Operations on CTTY return EBACKGROUND when we are not a
- foreground user of the tty. */
- mach_port_t tmp = port;
- port = ctty;
- ctty = tmp;
- }
- else
+ if (!is_ctty || __term_open_ctty (port, _hurd_pid, _hurd_pgrp, &ctty) != 0)
/* XXX if IS_CTTY, then this port is our ctty, but we are
not doing ctty style i/o because term_become_ctty barfed.
What to do? */