mirror of
https://github.com/MariaDB/server.git
synced 2025-12-24 11:21:21 +03:00
my_pthread.h:
Let pthread_mutex_init() macro return 0 on Windows mysql_priv.h: Return type is to be 'my_bool' for 'opt_enable_shared_memory'
This commit is contained in:
@@ -144,7 +144,7 @@ extern int pthread_mutex_destroy (pthread_mutex_t *);
|
||||
#define pthread_kill(A,B) raise(B)
|
||||
#define pthread_exit(A) pthread_dummy()
|
||||
#else
|
||||
#define pthread_mutex_init(A,B) InitializeCriticalSection(A)
|
||||
#define pthread_mutex_init(A,B) (InitializeCriticalSection(A),0)
|
||||
#define pthread_mutex_lock(A) (EnterCriticalSection(A),0)
|
||||
#define pthread_mutex_trylock(A) (WaitForSingleObject((A), 0) == WAIT_TIMEOUT)
|
||||
#define pthread_mutex_unlock(A) LeaveCriticalSection(A)
|
||||
|
||||
Reference in New Issue
Block a user