diff --git a/src/common/compat.c b/src/common/compat.c index 0b5de082cc..ae1b58653a 100644 --- a/src/common/compat.c +++ b/src/common/compat.c @@ -678,7 +678,9 @@ void spawn_exit() #elif defined(USE_PTHREADS) pthread_exit(NULL); #else - exit(0); + /* http://www.erlenstar.demon.co.uk/unix/faq_2.html says we should + * call _exit, not exit, from child processes. */ + _exit(0); #endif }