summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libexec/getty/main.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libexec/getty/main.c b/libexec/getty/main.c
index a57128131c3..23af8cf0cda 100644
--- a/libexec/getty/main.c
+++ b/libexec/getty/main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: main.c,v 1.50 2018/11/15 03:04:10 deraadt Exp $ */
+/* $OpenBSD: main.c,v 1.51 2018/11/17 01:40:51 deraadt Exp $ */
/*-
* Copyright (c) 1980, 1993
@@ -261,6 +261,7 @@ main(int argc, char *argv[])
gettable(tname, tabent);
if (strcmp(LO, saveLO) != 0) {
/* re-exec to apply new unveil */
+ closefrom(0);
execv(_PATH_GETTY, argv);
exit(0);
}