feat/update_config #10
@ -113,6 +113,7 @@ private:
|
||||
}
|
||||
|
||||
private:
|
||||
friend class ScopedLock;
|
||||
CondVarProxy proxy_;
|
||||
};
|
||||
}// namespace cond_var
|
||||
|
@ -3,7 +3,6 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "tile/base/thread/cond_var.h"
|
||||
#include "tile/base/thread/mutex.h"
|
||||
#include "tile/base/thread/scoped_lock.h"
|
||||
|
||||
@ -30,7 +29,7 @@ public:
|
||||
inline void Wait()
|
||||
{
|
||||
ScopedLock _(m_);
|
||||
cv_.Wait(m_, [this] { return signaled_; });
|
||||
cv_.Wait(_, [this] { return signaled_; });
|
||||
ResetIfNeeded();
|
||||
}
|
||||
|
||||
@ -49,7 +48,7 @@ public:
|
||||
bool WaitUntil(const std::chrono::time_point<Clock, Duration> &timeout_time)
|
||||
{
|
||||
ScopedLock _(m_);
|
||||
if (cv_.WaitUntil(m_, timeout_time, [this] { return signaled_; })) {
|
||||
if (cv_.WaitUntil(_, timeout_time, [this] { return signaled_; })) {
|
||||
ResetIfNeeded();
|
||||
return true;
|
||||
}
|
||||
|
@ -39,7 +39,6 @@
|
||||
#include "tile/base/write_mostly.h"
|
||||
|
||||
// Sync
|
||||
#include "tile/base/thread/cond_var.h"
|
||||
#include "tile/base/thread/event.h"
|
||||
#include "tile/base/thread/latch.h"
|
||||
#include "tile/base/thread/mutex.h"
|
||||
|
Loading…
Reference in New Issue
Block a user