123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475 |
- #include "test.h"
- static void *
- func(void * arg)
- {
- pte_osThreadSleep(2000);
- pthread_exit(arg);
-
- exit(1);
- return 0;
- }
- int pthread_test_join0()
- {
- pthread_t id;
- int result;
-
- assert(pthread_create(&id, NULL, func, (void *) 123) == 0);
- assert(pthread_join(id, (void **) &result) == 0);
- assert(result == 123);
-
- return 0;
- }
|