NAME | SYNOPSIS | API RESTRICTIONS | DESCRIPTION | RETURN VALUES | ATTRIBUTES | SEE ALSO
$(OS_DIR)/lib/libc.a #include <unistd.h>unsigned int alarm(unsigned int seconds);
The function or functions documented here may not be used safely in all application contexts with all APIs provided in the ChorusOS 5.0 product.
See API(5FEA) for details.
The alarm() sets a timer to deliver the signal SIGALRM to the calling process after the specified number of seconds.
If an alarm has already been set with alarm() but has not been delivered, another call to alarm() will supersede the prior call.
The request alarm0() nullifies the current alarm and the signal SIGALRM will not be delivered.
The maximum number of seconds allowed is 100000000.
The return value of alarm() is the amount of time left on the timer from a previous call to alarm(). If no alarm is set, the return value is 0.
See attributes(5) for descriptions of the following attributes:
ATTRIBUTE TYPE | ATTRIBUTE VALUE |
---|---|
Interface Stability | Evolving |
NAME | SYNOPSIS | API RESTRICTIONS | DESCRIPTION | RETURN VALUES | ATTRIBUTES | SEE ALSO