Esempio n. 1
0
    void Listener::wakeup(STATE) {
      MachineThread::wakeup(state);

      while(thread_running_p()) {
        if(write(fd_, "\0", 1) < 0) {
          logger::error("%s: console: unable to wake listener thread", strerror(errno));
        }
      }
    }
Esempio n. 2
0
    void FinalizerThread::wakeup(STATE) {
      MachineThread::wakeup(state);

      while(thread_running_p()) {
        UnmanagedPhase unmanaged(state);
        std::lock_guard<std::mutex> guard(list_mutex());

        list_condition().notify_one();
      }
    }