summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason Evans <jasone@canonware.com>2016-11-03 01:05:19 (GMT)
committerJason Evans <jasone@canonware.com>2016-11-03 02:24:49 (GMT)
commit31db315f17a48380d11d5dd67dde154adf571573 (patch)
treea0a6aa53179dd90a70dbeeebb4b39c4266bf5756
parent07ee4c5ff4c60e8e04eb452e2ef154c47fa118a4 (diff)
downloadjemalloc-31db315f17a48380d11d5dd67dde154adf571573.zip
jemalloc-31db315f17a48380d11d5dd67dde154adf571573.tar.gz
jemalloc-31db315f17a48380d11d5dd67dde154adf571573.tar.bz2
Call _exit(2) rather than exit(3) in forked child.
_exit(2) is async-signal-safe, whereas exit(3) is not.
-rw-r--r--test/unit/fork.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/unit/fork.c b/test/unit/fork.c
index 46c815e..c530797 100644
--- a/test/unit/fork.c
+++ b/test/unit/fork.c
@@ -26,7 +26,7 @@ TEST_BEGIN(test_fork)
test_fail("Unexpected fork() failure");
} else if (pid == 0) {
/* Child. */
- exit(0);
+ _exit(0);
} else {
int status;