C programs that rely on POSIX standards
-
Signals are a limited form of inter-process communication (IPC)
-
Used in Unix, Unix-like, and other POSIX-compliant operating systems
-
Signal is an asynchronous notification sent to a process or to a specific thread within the same process in order to notify it of an event that occurred
-
When a signal is sent, the operating system interrupts the target process' normal flow of execution to deliver the signal
- If the process has previously registered a signal handler, that routine is executed
- Otherwise, the default signal handler is executed
#include <signal.h>
int sighold(int sig);
int sigignore(int sig);
int sigpause(int sig);
int sigrelse(int sig);
void (*sigset(int sig, void (*disp)(int)))(int);