add C11 thread creation and related thread functions
[musl] / src / thread / thrd_join.c
1 #include <stdint.h>
2 #include <threads.h>
3
4 int __pthread_join(thrd_t, void**);
5
6 int thrd_join(thrd_t t, int *res)
7 {
8         void *pthread_res;
9         __pthread_join(t, &pthread_res);
10         if (res) *res = (int)(intptr_t)pthread_res;
11         return thrd_success;
12 }