summaryrefslogtreecommitdiffstats
path: root/src/iperf_pthread.h
blob: 44828d6a9814948098630a8868d458fa5413bbbc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#include "iperf_config.h"

#if defined(HAVE_PTHREAD)

#include <pthread.h>

#if defined(__ANDROID__)

/* Adding missing `pthread` related definitions in Android.
 */

#define PTHREAD_CANCEL_ASYNCHRONOUS 0
#define PTHREAD_CANCEL_ENABLE NULL

int pthread_setcanceltype(int type, int *oldtype);
int pthread_setcancelstate(int state, int *oldstate);
int pthread_cancel(pthread_t thread_id);

#endif // defined(__ANDROID__)

#endif // defined(HAVE_PTHREAD)