mirror of https://git.musl-libc.org/git/musl
Browse Source
After commitmaster5b74eed3b3the timer thread doesn't check whether timer_create() actually created the timer, proceeding to wait for a signal that might never arrive. We can't fix this by simply checking for a negative timer_id after pthread_barrier_wait() because we have no way to distinguish a timer creation failure and a request to delete a timer with INT_MAX id if it happens to arrive quickly (a variation of this bug existed before5b74eed3b3, where the timer would be leaked in this case). So (ab)use cancel field of pthread_t instead.
committed by
Rich Felker
1 changed files with 5 additions and 1 deletions
Loading…
Reference in new issue