| 122 | } |
| 123 | |
| 124 | void thread_detach(void *thread) |
| 125 | { |
| 126 | #if defined(CONF_FAMILY_UNIX) |
| 127 | dbg_assert(pthread_detach((pthread_t)thread) == 0, "pthread_detach failure"); |
| 128 | #elif defined(CONF_FAMILY_WINDOWS) |
| 129 | dbg_assert(CloseHandle(thread), "CloseHandle failure"); |
| 130 | #else |
| 131 | #error not implemented |
| 132 | #endif |
| 133 | } |
| 134 | |
| 135 | void thread_init_and_detach(void (*threadfunc)(void *), void *u, const char *name) |
| 136 | { |
no outgoing calls