summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--usr.bin/login/login.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/usr.bin/login/login.c b/usr.bin/login/login.c
index 3e826d5..e671c8d 100644
--- a/usr.bin/login/login.c
+++ b/usr.bin/login/login.c
@@ -233,8 +233,7 @@ main(int argc, char *argv[])
setproctitle("-%s", getprogname());
- for (cnt = getdtablesize(); cnt > 2; cnt--)
- (void)close(cnt);
+ closefrom(3);
/*
* Get current TTY
OpenPOWER on IntegriCloud