An exception-safe wrapper around a child process from fork(). More...
#include <rutz/pipe.h>
Public Member Functions | |
child_process () | |
Fork a child process. | |
~child_process () throw () | |
Destructor waits for child process to complete. | |
bool | in_parent () const throw () |
Check if we're in the parent or child process after the fork(). | |
int | wait () throw () |
Wait for child process to complete, and return its status code. |
An exception-safe wrapper around a child process from fork().
Definition at line 105 of file pipe.h.
rutz::child_process::child_process | ( | ) |
rutz::child_process::~child_process | ( | ) | throw () |
bool rutz::child_process::in_parent | ( | ) | const throw () [inline] |
Check if we're in the parent or child process after the fork().
Definition at line 116 of file pipe.h.
Referenced by rutz::bidir_pipe::init().
int rutz::child_process::wait | ( | ) | throw () |
Wait for child process to complete, and return its status code.
Definition at line 138 of file pipe.cc.
Referenced by rutz::exec_pipe::exit_status(), rutz::bidir_pipe::exit_status(), and ~child_process().