Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Acquire the global lock before initializing malloc (#410)
In a multi-threaded execution we need to make sure that only exactly one thread initializes malloc. The function try_init_allocator() can't easily be made thread-safe, so just move the call to try_init_allocator() inside the block that holds the lock.
- Loading branch information