mirror of https://github.com/sipwise/sems.git
In some cases it can happen that ::join() is called from multiple threads at the same time. Checking the ::joinable() flag is not race-free and so is unreliable to make sure that only one other thread attempts to join at any given time. Add a mutex and a state variable to make sure only one thread attempts to join, and make any other threads wait. Change-Id: I02fd236a416b035c98642535f1521be4a3a63fd9mr13.3.1
parent
805aad91d2
commit
fb187929dd
Loading…
Reference in new issue