mirror of
https://github.com/rad4day/Waybar.git
synced 2023-12-21 10:22:59 +01:00
fix(thread): check before detach
This commit is contained in:
@ -74,7 +74,9 @@ struct SleeperThread {
|
||||
{
|
||||
do_run_ = false;
|
||||
condvar_.notify_all();
|
||||
thread_.detach();
|
||||
if (thread_.joinable()) {
|
||||
thread_.detach();
|
||||
}
|
||||
}
|
||||
|
||||
private:
|
||||
|
Reference in New Issue
Block a user