mirror of
https://github.com/Silicondust/libhdhomerun
synced 2025-08-20 13:33:29 -07:00
20221113
This commit is contained in:
parent
eda0b640ed
commit
8b8d3d7e5e
1 changed files with 2 additions and 10 deletions
|
@ -85,16 +85,8 @@ bool thread_task_create(thread_task_t *tid, thread_task_func_t func, void *arg)
|
||||||
|
|
||||||
void thread_task_join(thread_task_t tid)
|
void thread_task_join(thread_task_t tid)
|
||||||
{
|
{
|
||||||
while (1) {
|
WaitForSingleObject(tid, INFINITE);
|
||||||
DWORD ExitCode = 0;
|
CloseHandle(tid);
|
||||||
if (!GetExitCodeThread(tid, &ExitCode)) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (ExitCode != STILL_ACTIVE) {
|
|
||||||
CloseHandle(tid);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void thread_mutex_init(thread_mutex_t *mutex)
|
void thread_mutex_init(thread_mutex_t *mutex)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue