[ale] SIGALRM
Omar Loggiodice
ologgio at vrainn.com
Thu Jul 11 11:39:05 EDT 1996
Christopher Fowler Writes :
:
:Why would a program catch signal 14 (SIGALRM)?
:
There are many instances when processes want/need to be notified
asynchronously about timeouts, or need to perform a task if a certain amount
of time has elapsed.
As an example the "chat" program that comes with pppd uses this signal to
know if the timeout period has elapsed while waiting for an "expect" string.
It first sets the timeout period by calling alarm() (see the man pages) and
the signale handler for SIGALRM sets a variable that lets the rest of the
code know that the timeout period has elapsed.
Hope this concise explanation helps...
--
____________________________________________________________________
/ __ __ __ - __ __ / - _ __ ologgio at vrainn.com
Omar R. /__ /_/ /_/ /_/ / /_/ /_/ / /_ /-_ CIS: 74040,1543
__/ __/
___C++/6_yrs____Virtual Reality/4_yrs____Vorl_____Linux(free)_______
OO{A,D,P} := good!
More information about the Ale
mailing list