5 #ifndef TIMEOUTGUARD_H_ 6 #define TIMEOUTGUARD_H_ 31 void Init(pid_t _pid,
size_t _timeout)
34 throw std::logic_error(
"CTimeoutGuard is already initialized");
37 m_secTimeOut = _timeout;
50 if (m_pid > 0 && IsProcessExist(m_pid))
53 ::kill(m_pid, SIGTERM);
void Init(pid_t _pid, size_t _timeout)
Definition: TimeoutGuard.h:31
The class, which watches the running time of the process and sends SEGTERM when defined time-out is r...
Definition: TimeoutGuard.h:18
static CTimeoutGuard & Instance()
Definition: TimeoutGuard.h:42
boost::shared_ptr< boost::thread > Thread_PTR_t
A smart pointer wrapper for boost::thread pointers.
Definition: BOOSTHelper.h:50
void ThreadWorker() const
Definition: TimeoutGuard.h:47
Miscellaneous functions and helpers are located here.
Definition: BOOST_FILESYSTEM.h:21