return whether worker is alive
| 441 | |
| 442 | //! return whether worker is alive |
| 443 | bool check_worker_alive() { |
| 444 | if (m_worker_pid) { |
| 445 | auto wait_ret = waitpid(m_worker_pid, nullptr, WNOHANG); |
| 446 | CHECK_SYS_ERR(wait_ret); |
| 447 | if (!wait_ret) |
| 448 | return true; |
| 449 | } |
| 450 | return false; |
| 451 | } |
| 452 | |
| 453 | //! start worker if it is not alive |
| 454 | void ensure_worker_alive() { |
no outgoing calls
no test coverage detected