diff options
author | 1997-08-29 17:59:51 +0000 | |
---|---|---|
committer | 1997-08-29 17:59:51 +0000 | |
commit | 2f9d5d42335515523bc9ea10e263eeeb68012508 (patch) | |
tree | 3e21b93b62cd45378064fe90efb901e845b94fc9 | |
parent | s/XXX/__MBR_XXX/ and undef it after use (diff) | |
download | wireguard-openbsd-2f9d5d42335515523bc9ea10e263eeeb68012508.tar.xz wireguard-openbsd-2f9d5d42335515523bc9ea10e263eeeb68012508.zip |
if O_NOCTTY is supplied to open(2) do *not* aquire a controlling tty
-rw-r--r-- | sys/compat/svr4/svr4_fcntl.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/compat/svr4/svr4_fcntl.c b/sys/compat/svr4/svr4_fcntl.c index aec986a376c..91a269cc917 100644 --- a/sys/compat/svr4/svr4_fcntl.c +++ b/sys/compat/svr4/svr4_fcntl.c @@ -1,4 +1,4 @@ -/* $OpenBSD: svr4_fcntl.c,v 1.6 1997/08/07 09:16:20 niklas Exp $ */ +/* $OpenBSD: svr4_fcntl.c,v 1.7 1997/08/29 17:59:51 kstailey Exp $ */ /* $NetBSD: svr4_fcntl.c,v 1.14 1995/10/14 20:24:24 christos Exp $ */ /* @@ -261,7 +261,7 @@ svr4_sys_open(p, v, retval) if (error) return error; - if ((SCARG(&cup, flags) & O_NOCTTY) && SESS_LEADER(p) && + if (!(SCARG(&cup, flags) & O_NOCTTY) && SESS_LEADER(p) && !(p->p_flag & P_CONTROLT)) { struct filedesc *fdp = p->p_fd; struct file *fp = fdp->fd_ofiles[*retval]; |