SLEEP

Section: C Library Functions (3)
Updated: August 1, 1992
Index Return to Main Contents
 

NAME

sleep - suspend execution for interval  

SYNOPSIS

int sleep(unsigned int seconds);
 

DESCRIPTION

The current process is suspended from execution for the number of seconds specified by the argument. The actual suspension time may be up to 1 second less than that requested, because scheduled wakeups occur at fixed 1-second intervals, and an arbitrary amount longer because of other activity in the system.  

RETURNS

If the sleep function returns because the requested time has elapsed, the value returned will be zero. If the sleep function returns due to the delivery of a signal, the value returned is the requested time minus the time actually slept, in seconds.  

ERRORS

[EAGAIN]
A resource is temporarily unavailable.
 

SEE ALSO

alarm(3C), pause(2P), setitimeer(2), sigaction(2P), sigpause(2), usleep(3)


 

Index

NAME
SYNOPSIS
DESCRIPTION
RETURNS
ERRORS
SEE ALSO

This document was created by man2html, using the manual pages.
Time: 00:57:06 GMT, September 26, 2024