SLEEP(3)

NAME
sleep - suspend process execution for interval of seconds

SYNOPSIS
#include <unistd.h>

unsigned int sleep (unsigned int seconds);

DESCRIPTION
The sleep function suspends execution of the calling process for seconds of time. System activity or time spent in processing the call may lengthen the sleep by a second. Because scheduled wakeups occur at fixed 1-second intervals, the actual suspension time may also be up to 1 second less than requested.

This function is implemented using alarm(2) and sigpause(2).

RETURN VALUES
This implementation of sleep always returns zero.

SEE ALSO
sigpause(2)

HISTORY
A sleep function appeared in v7.