mirror of
https://github.com/TomHarte/CLK.git
synced 2025-03-25 06:30:38 +00:00
Fix construction order.
This commit is contained in:
parent
07ce0f0133
commit
5c3084c37c
@ -84,10 +84,13 @@ template <typename Performer> class AsyncUpdater {
|
||||
std::unique_ptr<ActionVector> actions_;
|
||||
|
||||
// Necessary synchronisation parts.
|
||||
std::thread performer_thread_;
|
||||
std::atomic<bool> should_quit = false;
|
||||
std::mutex condition_mutex_;
|
||||
std::condition_variable condition_;
|
||||
std::atomic<bool> should_quit = false;
|
||||
|
||||
// Ensure the thread isn't constructed until after the mutex
|
||||
// and condition variable.
|
||||
std::thread performer_thread_;
|
||||
};
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user