]> granicus.if.org Git - postgresql/blob - src/interfaces/libpq/pthread-win32.h
The attached patch updates the thread test program to run stand-alone on
[postgresql] / src / interfaces / libpq / pthread-win32.h
1 #ifndef __PTHREAD_H
2 #define __PTHREAD_H
3
4 typedef ULONG pthread_key_t;
5 typedef HANDLE pthread_mutex_t;
6 typedef int pthread_once_t;
7
8 HANDLE pthread_self();
9
10 void pthread_setspecific(pthread_key_t, void*);
11 void* pthread_getspecific(pthread_key_t);
12
13 void pthread_mutex_init(pthread_mutex_t *, void *attr);
14 void pthread_mutex_lock(pthread_mutex_t*); // blocking
15 void pthread_mutex_unlock(pthread_mutex_t*);
16
17 #endif