From e77fa59ece7e23de586f08980f627b8102511755 Mon Sep 17 00:00:00 2001 From: Mike Hommey Date: Wed, 28 Mar 2012 09:53:16 +0200 Subject: [PATCH] Don't use pthread_atfork to register prefork/postfork handlers on OSX OSX libc calls zone allocators' force_lock/force_unlock already. --- src/jemalloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/jemalloc.c b/src/jemalloc.c index ee771c78..9eae1372 100644 --- a/src/jemalloc.c +++ b/src/jemalloc.c @@ -575,7 +575,7 @@ malloc_init_hard(void) malloc_conf_init(); -#ifndef JEMALLOC_MUTEX_INIT_CB +#if (!defined(JEMALLOC_MUTEX_INIT_CB) && !defined(JEMALLOC_ZONE)) /* Register fork handlers. */ if (pthread_atfork(jemalloc_prefork, jemalloc_postfork_parent, jemalloc_postfork_child) != 0) {