1
0
mirror of https://github.com/TomHarte/CLK.git synced 2026-04-25 11:17:26 +00:00

Switch to lambda form.

This commit is contained in:
Thomas Harte
2025-11-09 21:09:57 -05:00
parent 902f388cb1
commit a81309433c
+3 -3
View File
@@ -164,9 +164,9 @@ private:
while(!should_quit_.load(std::memory_order_relaxed)) {
// Wait for new actions to be signalled, and grab them.
std::unique_lock lock(condition_mutex_);
while(actions_.empty() && !should_quit_.load(std::memory_order_relaxed)) {
condition_.wait(lock);
}
condition_.wait(lock, [&] {
return !actions_.empty() || should_quit_.load(std::memory_order_relaxed);
});
std::swap(actions, actions_);
lock.unlock();