From: Dmitry Ivankov (divanorama_at_[hidden])
Date: 2007-01-12 13:46:38


But just wait in threads is bad, because of spurious wake ups. It should be
like

while (!::we_can_start)
  g_some_cond.wait(condition_lock);

and

::we_can_start = true;
condition_lock.notify_all();