summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to 'bin')
-rw-r--r--bin/csh/csh.c6
-rw-r--r--bin/ksh/main.c6
2 files changed, 8 insertions, 4 deletions
diff --git a/bin/csh/csh.c b/bin/csh/csh.c
index 4d9001a47dd..09a34859054 100644
--- a/bin/csh/csh.c
+++ b/bin/csh/csh.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: csh.c,v 1.35 2015/10/28 22:18:53 naddy Exp $ */
+/* $OpenBSD: csh.c,v 1.36 2015/11/11 02:52:46 deraadt Exp $ */
/* $NetBSD: csh.c,v 1.14 1995/04/29 23:21:28 mycroft Exp $ */
/*-
@@ -152,8 +152,10 @@ main(int argc, char *argv[])
(void) time(&chktim);
if (pledge("stdio rpath wpath cpath fattr getpw proc exec tty",
- NULL) == -1)
+ NULL) == -1) {
perror("pledge");
+ exit(1);
+ }
/*
* Move the descriptors to safe places. The variable didfds is 0 while we
diff --git a/bin/ksh/main.c b/bin/ksh/main.c
index 301f6666de2..ea2e6714e1b 100644
--- a/bin/ksh/main.c
+++ b/bin/ksh/main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: main.c,v 1.73 2015/11/01 15:38:53 mmcc Exp $ */
+/* $OpenBSD: main.c,v 1.74 2015/11/11 02:52:46 deraadt Exp $ */
/*
* startup, main loop, environments and error handling
@@ -151,8 +151,10 @@ main(int argc, char *argv[])
#ifndef MKNOD
if (pledge("stdio rpath wpath cpath fattr flock getpw proc exec tty",
- NULL) == -1)
+ NULL) == -1) {
perror("pledge");
+ exit(1);
+ }
#endif
ainit(&aperm); /* initialize permanent Area */