remove NullCondition unused code

pull/13/head
Jeff Becker 6 years ago
parent 6a828ea985
commit 54f70f370a
No known key found for this signature in database
GPG Key ID: F357B3B42F6F9B05

@ -29,48 +29,9 @@ namespace llarp
}
};
/// a condition variable that does nothing
struct NullCondition
{
template < typename Lock_t >
void
wait(Lock_t& l)
{
}
template < typename Lock_t, typename Pred >
void
wait(Lock_t& l, Pred p)
{
}
void
notify_one()
{
}
void
notify_all()
{
}
template < typename Interval >
void
wait_for(NullLock& l, Interval i)
{
std::this_thread::sleep_for(i);
}
};
#ifdef SHADOW_TESTNET
typedef NullMutex mtx_t;
typedef NullLock lock_t;
typedef NullCondition cond_t;
#else
typedef std::mutex mtx_t;
typedef std::unique_lock< std::mutex > lock_t;
typedef std::condition_variable cond_t;
#endif
struct Mutex
{

Loading…
Cancel
Save