diff options
Diffstat (limited to 'src/port')
-rw-r--r-- | src/port/pthread-win32.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/port/pthread-win32.h b/src/port/pthread-win32.h index 97ccc17..5f33269 100644 --- a/src/port/pthread-win32.h +++ b/src/port/pthread-win32.h @@ -5,7 +5,16 @@ #define __PTHREAD_H typedef ULONG pthread_key_t; -typedef CRITICAL_SECTION *pthread_mutex_t; + +typedef struct pthread_mutex_t +{ + /* initstate = 0: not initialized; 1: init done; 2: init in progress */ + LONG initstate; + CRITICAL_SECTION csection; +} pthread_mutex_t; + +#define PTHREAD_MUTEX_INITIALIZER { 0 } + typedef int pthread_once_t; DWORD pthread_self(void); |