mirror of
https://github.com/microsoft/mimalloc.git
synced 2025-07-06 11:34:38 +03:00
fix pthread initalization of mutexes
This commit is contained in:
parent
768872e4e0
commit
6b15342709
2 changed files with 5 additions and 4 deletions
|
@ -441,13 +441,13 @@ static inline void mi_lock_release(mi_lock_t* lock) {
|
|||
pthread_mutex_unlock(lock);
|
||||
}
|
||||
static inline void mi_lock_init(mi_lock_t* lock) {
|
||||
(void)(lock);
|
||||
pthread_mutex_init(lock, NULL);
|
||||
}
|
||||
static inline void mi_lock_done(mi_lock_t* lock) {
|
||||
(void)(lock);
|
||||
pthread_mutex_destroy(lock);
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
#elif defined(__cplusplus)
|
||||
|
||||
#include <mutex>
|
||||
|
@ -469,6 +469,7 @@ static inline void mi_lock_init(mi_lock_t* lock) {
|
|||
static inline void mi_lock_done(mi_lock_t* lock) {
|
||||
(void)(lock);
|
||||
}
|
||||
*/
|
||||
|
||||
#else
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue