#pragma once #include #if defined(__BIONIC__) #ifndef PTHREAD_CANCEL_ENABLE #define PTHREAD_CANCEL_ENABLE 0 #endif #ifndef PTHREAD_CANCEL_DISABLE #define PTHREAD_CANCEL_DISABLE 0 #endif static inline int pthread_setcancelstate(int state, int *oldstate) { if (oldstate) *oldstate = state; return 0; } static inline int pthread_cancel(pthread_t t) { (void)t; return 0; } #endif