Fix witness/fork() interactions.

Fix witness to clear its list of owned mutexes in the child if
platform-specific malloc_mutex code re-initializes mutexes rather than
unlocking them.
This commit is contained in:
Jason Evans
2016-04-26 10:47:22 -07:00
parent 174c0c3a9c
commit 108c4a11e9
5 changed files with 42 additions and 9 deletions

View File

@@ -594,7 +594,8 @@ witness_lock_error
witness_lockless_error
witness_not_owner_error
witness_owner_error
witness_postfork
witness_postfork_child
witness_postfork_parent
witness_prefork
witness_unlock
witnesses_cleanup

View File

@@ -96,7 +96,8 @@ void witness_assert_lockless(tsd_t *tsd);
void witnesses_cleanup(tsd_t *tsd);
void witness_fork_cleanup(tsd_t *tsd);
void witness_prefork(tsd_t *tsd);
void witness_postfork(tsd_t *tsd);
void witness_postfork_parent(tsd_t *tsd);
void witness_postfork_child(tsd_t *tsd);
#endif /* JEMALLOC_H_EXTERNS */
/******************************************************************************/