diff options
author | 2010-03-11 21:32:28 +0000 | |
---|---|---|
committer | 2010-03-11 21:32:28 +0000 | |
commit | ca19f200d0b29b156cb28730122f145b2a99ecd6 (patch) | |
tree | 1dcdcf449ccea1b26267e1d5219793690dc6161d | |
parent | Correct a wrong printf and move a check than should be before the debug. (diff) | |
download | wireguard-openbsd-ca19f200d0b29b156cb28730122f145b2a99ecd6.tar.xz wireguard-openbsd-ca19f200d0b29b156cb28730122f145b2a99ecd6.zip |
Fix intended use of closefrom() so that we do indeed close fd 3 and up by
default and make -C work as expected.
fine by kettenis@, beck@, millert@
-rw-r--r-- | usr.bin/sudo/sudo.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/sudo/sudo.c b/usr.bin/sudo/sudo.c index 3ec16e83dc8..b9a7031e284 100644 --- a/usr.bin/sudo/sudo.c +++ b/usr.bin/sudo/sudo.c @@ -536,7 +536,7 @@ main(argc, argv, envp) sudo_endpwent(); sudo_endgrent(); - closefrom(def_closefrom + 1); + closefrom(def_closefrom); #ifndef PROFILING if (ISSET(sudo_mode, MODE_BACKGROUND) && fork() > 0) { |