summaryrefslogtreecommitdiff
path: root/libexec/rexecd/rexecd.c
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>1999-08-17 09:13:17 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>1999-08-17 09:13:17 +0000
commit63b7a98cc57e3a3fbf4e70bcd27a4eb65721c359 (patch)
tree04f5f18255e1ed724e1267f93be97b3001966d2b /libexec/rexecd/rexecd.c
parentfe89691a2e6a46dc13e58dde591c3c37ac355e5c (diff)
More <sys/file.h> vs. <fcntl.h> and open() flags fixes.
Diffstat (limited to 'libexec/rexecd/rexecd.c')
-rw-r--r--libexec/rexecd/rexecd.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/libexec/rexecd/rexecd.c b/libexec/rexecd/rexecd.c
index 6ffbafea41d..8436c6bf08d 100644
--- a/libexec/rexecd/rexecd.c
+++ b/libexec/rexecd/rexecd.c
@@ -39,7 +39,7 @@ char copyright[] =
#ifndef lint
/*static char sccsid[] = "from: @(#)rexecd.c 5.12 (Berkeley) 2/25/91";*/
-static char rcsid[] = "$Id: rexecd.c,v 1.11 1998/07/10 08:06:08 deraadt Exp $";
+static char rcsid[] = "$Id: rexecd.c,v 1.12 1999/08/17 09:13:13 millert Exp $";
#endif /* not lint */
#include <sys/param.h>
@@ -50,6 +50,7 @@ static char rcsid[] = "$Id: rexecd.c,v 1.11 1998/07/10 08:06:08 deraadt Exp $";
#include <netdb.h>
#include <pwd.h>
#include <errno.h>
+#include <fcntl.h>
#include <unistd.h>
#include <stdio.h>
#include <stdlib.h>
@@ -129,7 +130,7 @@ doit(f, fromp)
(void) signal(SIGQUIT, SIG_DFL);
(void) signal(SIGTERM, SIG_DFL);
#ifdef DEBUG
- { int t = open(_PATH_TTY, 2);
+ { int t = open(_PATH_TTY, O_RDWR);
if (t >= 0) {
ioctl(t, TIOCNOTTY, (char *)0);
(void) close(t);