3 ms·
> The proper fix for this is to wait on a condition variable, which will make sure the thread remains inactive when idle. In case that phrase confuses others r
by otikik 12y ago
> The proper fix for this is to wait on a condition variable, which will make sure the thread remains inactive when idle.
In case that phrase confuses others reading that: a Condition Variable is a sync-related construct - like Mutex or Semaphore. It does not mean "a regular variable that you put on an if". A very bad name for the concept in my opinion.
http://en.cppreference.com/w/cpp/thread/condition_variable http://en.cppreference.com/w/cpp/thread/condition_variable