|
|
|
Pause waits signal, alarm sends signal when timer fires.
Sleep:
signal(SIGALRM, function);
alarm(seconds);
pause();
-----------------------
void function()
{
.................
}
Delete "timer": alarm(0)
Bsd and System V differs in the signal handling.
|
|
|