The GNU C Library - Waiting for a Signal

Node: Waiting for a Signal Next: Signal Stack Prev: Blocking Signals Up: Signal Handling

Waiting for a Signal

If your program is driven by external events, or uses signals for synchronization, then when it has nothing to do it should probably wait until a signal arrives.

Using Pause The simple way, using pause .
Pause Problems Why the simple way is often not very good.
Sigsuspend Reliably waiting for a specific signal.


Next: Signal Stack Up: Signal Handling