MCPcopy Create free account
hub / github.com/RT-Thread/rt-thread / wait

Method wait

components/libc/cplusplus/cpp11/gcc/condition_variable.cpp:15–23  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

13namespace std
14{
15 void condition_variable::wait(unique_lock<mutex>& lock)
16 {
17 int err = pthread_cond_wait(&_m_cond, lock.mutex()->native_handle());
18
19 if (err)
20 {
21 throw_system_error(err, "condition_variable::wait: failed to wait on a condition");
22 }
23 }
24
25 void notify_all_at_thread_exit(condition_variable& cond, unique_lock<mutex> lk)
26 {

Callers

nothing calls this directly

Calls 2

pthread_cond_waitFunction · 0.85
throw_system_errorFunction · 0.85

Tested by

no test coverage detected