Anope IRC Services  Version 2.0
pthread.h
Go to the documentation of this file.
1  /* POSIX emulation layer for Windows.
2  *
3  * Copyright (C) 2008-2014 Anope Team <team@anope.org>
4  *
5  * Please read COPYING and README for further details.
6  */
7 
8 #include <Windows.h>
9 
10 typedef HANDLE pthread_t;
11 typedef CRITICAL_SECTION pthread_mutex_t;
12 typedef HANDLE pthread_cond_t;
13 typedef int pthread_attr_t;
14 typedef void pthread_mutexattr_t;
15 typedef void pthread_condattr_t;
16 
17 #define PTHREAD_CREATE_JOINABLE 0
18 
19 extern int pthread_attr_init(pthread_attr_t *);
21 extern int pthread_create(pthread_t *, const pthread_attr_t *, void *(*)(void *), void *);
22 extern int pthread_join(pthread_t, void **);
23 extern void pthread_exit(int);
24 
30 
int pthread_cond_init(pthread_cond_t *, const pthread_condattr_t *)
Definition: pthread.cpp:94
int pthread_cond_signal(pthread_cond_t *)
Definition: pthread.cpp:107
void pthread_mutexattr_t
Definition: pthread.h:14
CRITICAL_SECTION pthread_mutex_t
Definition: pthread.h:11
int pthread_attr_init(pthread_attr_t *)
Definition: pthread.cpp:24
void pthread_exit(int)
Definition: pthread.cpp:60
int pthread_join(pthread_t, void **)
Definition: pthread.cpp:52
int pthread_mutex_unlock(pthread_mutex_t *)
Definition: pthread.cpp:88
int pthread_mutex_destroy(pthread_mutex_t *)
Definition: pthread.cpp:71
int pthread_cond_destroy(pthread_cond_t *)
Definition: pthread.cpp:102
void pthread_condattr_t
Definition: pthread.h:15
int pthread_mutex_lock(pthread_mutex_t *)
Definition: pthread.cpp:77
int pthread_cond_wait(pthread_cond_t *, pthread_mutex_t *)
Definition: pthread.cpp:112
int pthread_attr_t
Definition: pthread.h:13
int pthread_attr_setdetachstate(pthread_attr_t *, int)
Definition: pthread.cpp:30
int pthread_mutex_init(pthread_mutex_t *, const pthread_mutexattr_t *)
Definition: pthread.cpp:65
int pthread_create(pthread_t *, const pthread_attr_t *, void *(*)(void *), void *)
HANDLE pthread_cond_t
Definition: pthread.h:12
HANDLE pthread_t
Definition: pthread.h:10
int pthread_mutex_trylock(pthread_mutex_t *)
Definition: pthread.cpp:83