From a4f830f143e625710f6cc5f9dd63965b66ad0989 Mon Sep 17 00:00:00 2001 From: Jason Felice Date: Fri, 7 Dec 2018 09:36:06 -0500 Subject: [PATCH] Use _exit() after vfork() Closes #2620 The docs for Mac OS X's vfork() requires it, and _exit() conforms to POSIX.1-2008. http://man7.org/linux/man-pages/man2/_exit.2.html --- src/shell_manager.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shell_manager.cc b/src/shell_manager.cc index 065a9f74..6181ab63 100644 --- a/src/shell_manager.cc +++ b/src/shell_manager.cc @@ -123,7 +123,7 @@ pid_t spawn_shell(const char* shell, StringView cmdline, setup_child(); execve(shell, (char* const*)execparams.data(), (char* const*)envptrs.data()); - exit(-1); + _exit(-1); return -1; }