Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Ensure we use a MPMC queue in ThreadDeathWatcher as it may be used fr… #6149
…om multiple threads at the same time.
We used a MPSC queue in ThreadDeathWatcher and checked if it empty via isEmpty() from multiple threads if very unlucky. Depending on the implementation this is not safe and may even produce things like live-locks.
Change to use a MPMC queue.
No more risk to run into issues when multiple threads call watch(...) / unwatch(...) concurrently.