| 737 | |
| 738 | |
| 739 | static int pthread_setcancelstate(int state, int *oldstate) |
| 740 | { |
| 741 | pthread_t t = pthread_self(); |
| 742 | |
| 743 | if ((state & PTHREAD_CANCEL_ENABLE) != state) return EINVAL; |
| 744 | if (oldstate) *oldstate = t->p_state & PTHREAD_CANCEL_ENABLE; |
| 745 | t->p_state &= ~PTHREAD_CANCEL_ENABLE; |
| 746 | t->p_state |= state; |
| 747 | |
| 748 | return 0; |
| 749 | } |
| 750 | |
| 751 | static int pthread_setcanceltype(int type, int *oldtype) |
| 752 | { |
nothing calls this directly
no test coverage detected