39 lines
		
	
	
		
			1.0 KiB
		
	
	
	
		
			Groff
		
	
	
	
	
	
			
		
		
	
	
			39 lines
		
	
	
		
			1.0 KiB
		
	
	
	
		
			Groff
		
	
	
	
	
	
| .\" Copyright (c) 1980 Regents of the University of California.
 | |
| .\" All rights reserved.  The Berkeley software License Agreement
 | |
| .\" specifies the terms and conditions for redistribution.
 | |
| .\"
 | |
| .\"	@(#)alarm.3c	6.3 (Berkeley) 5/27/86
 | |
| .\"
 | |
| .TH ALARM 2  "May 27, 1986"
 | |
| .UC 4
 | |
| .SH NAME
 | |
| alarm \- schedule signal after specified time
 | |
| .SH SYNOPSIS
 | |
| .nf
 | |
| .ft B
 | |
| #include <unistd.h>
 | |
| 
 | |
| unsigned int alarm(unsigned int \fIseconds\fP)
 | |
| .ft R
 | |
| .fi
 | |
| .SH DESCRIPTION
 | |
| .B Alarm
 | |
| causes signal SIGALRM, see
 | |
| .BR sigaction (2),
 | |
| to be sent to the invoking process
 | |
| in a number of seconds given by the argument.
 | |
| Unless caught or ignored, the signal terminates the process.
 | |
| .PP
 | |
| Alarm requests are not stacked; successive calls reset the alarm clock.
 | |
| If the argument is 0, any alarm request is canceled.
 | |
| Because of scheduling delays,
 | |
| resumption of execution of when the signal is
 | |
| caught may be delayed an arbitrary amount.
 | |
| .PP
 | |
| The return value is the amount of time previously remaining in the alarm clock.
 | |
| .SH "SEE ALSO"
 | |
| .BR pause (2),
 | |
| .BR sigsuspend (2),
 | |
| .BR sigaction (2),
 | |
| .BR sleep (3).
 | 
