aboutsummaryrefslogtreecommitdiff
path: root/src/libutil
diff options
context:
space:
mode:
Diffstat (limited to 'src/libutil')
-rw-r--r--src/libutil/util.cc12
-rw-r--r--src/libutil/util.hh4
2 files changed, 3 insertions, 13 deletions
diff --git a/src/libutil/util.cc b/src/libutil/util.cc
index afb0dc0b2..bfed96846 100644
--- a/src/libutil/util.cc
+++ b/src/libutil/util.cc
@@ -847,9 +847,9 @@ void killUser(uid_t uid)
} catch (std::exception & e) {
std::cerr << format("killing processes belonging to uid `%1%': %2%")
% uid % e.what() << std::endl;
- quickExit(1);
+ _exit(1);
}
- quickExit(0);
+ _exit(0);
}
/* parent */
@@ -905,7 +905,7 @@ string runProgram(Path program, bool searchPath, const Strings & args)
} catch (std::exception & e) {
std::cerr << "error: " << e.what() << std::endl;
}
- quickExit(1);
+ _exit(1);
}
/* Parent. */
@@ -944,12 +944,6 @@ void closeOnExec(int fd)
}
-void quickExit(int status)
-{
- _exit(status);
-}
-
-
void setuidCleanup()
{
/* Don't trust the environment. */
diff --git a/src/libutil/util.hh b/src/libutil/util.hh
index d3861f730..0e121ea5c 100644
--- a/src/libutil/util.hh
+++ b/src/libutil/util.hh
@@ -262,10 +262,6 @@ void closeMostFDs(const set<int> & exceptions);
/* Set the close-on-exec flag for the given file descriptor. */
void closeOnExec(int fd);
-/* Wrapper around _exit() on Unix and ExitProcess() on Windows. (On
- Cygwin, _exit() doesn't seem to do the right thing.) */
-void quickExit(int status);
-
/* Common initialisation for setuid programs: clear the environment,
sanitize file handles 0, 1 and 2. */
void setuidCleanup();