Go to the documentation of this file.
16 #include <sys/types.h>
19 # include <sys/wait.h>
35 #if defined (__FreeBSD__) || defined(__FreeBSD_kernel__) || defined (__NetBSD__)
36 # define ASSAIOSIG SIGIO
38 # define ASSAIOSIG SIGPOLL
84 if (signum_ == SIGINT) {
126 if (signum_ == SIGUSR1) {
164 if (signum_ == SIGUSR2) {
200 if (signum_ == SIGCHLD && wait(NULL) != -1) {
234 if (signum_ == SIGALRM) {
278 #endif // !defined(WIN32)
sig_atomic_t m_alarm_flag
Indicator whether alarm gone off yet.
int handle_signal(int signum_)
Catch USR2 signal and increment count.
sig_atomic_t m_count
Received signals count.
int handle_signal(int signum_)
Catch USR1 signal and increment count.
SIGPOLLHandler()
Constructor.
sig_atomic_t m_count
Received signals count.
void resetState()
Set received signals count back to 0.
SIGALRMHandler()
Constructor.
int handle_signal(int signum_)
Catch and absorb SIGPOLL signal.
@ TRACE
Function call trace
sig_atomic_t alarmed()
Has alarm gone off?
Class SIGUSR2Handler handles SIGUSR2 signal.
Class SIGPOLLHandler handles SIGPOLL signal.
int handle_signal(int signum_)
Receive ALRM signal.
sig_atomic_t child_exited()
Did child exit?
SIGCHLDHandler()
Constructor.
sig_atomic_t m_child_exit_flag
Child exit's state.
void resetState()
Set received signals count back to 0.
SIGUSR2Handler()
Constructor.
void resetState()
Reset state of the object to initial.
void resetState()
Reset internal state.
SIGINTHandler handles SIGINT signal.
sig_atomic_t received_count() const
Report count of received signals.
SIGUSR1Handler()
Constructor.
sig_atomic_t received_count() const
Report count of received signals.
sig_atomic_t m_graceful_quit
flag that indicates whether signal was caught.
void resetState()
Reset child's exit state.
Class SIGALRMHandler handles SIGALRM signal.
sig_atomic_t graceful_quit()
Indicates whether graceful quit signal has been raised by the signal handler.
Class SIGCHLDHandler handles SIGCHLD signal.
SIGINTHandler()
constructor
int handle_signal(int signum_)
Receive CHLD signal.
@ SIGHAND
Class SigHandler(s) messages
int handle_signal(int signum_)
Receive SIGINT signal.
#define trace_with_mask(s, m)