1PAUSE(3P)                  POSIX Programmer's Manual                 PAUSE(3P)
2
3
4

PROLOG

6       This  manual  page is part of the POSIX Programmer's Manual.  The Linux
7       implementation of this interface may differ (consult the  corresponding
8       Linux  manual page for details of Linux behavior), or the interface may
9       not be implemented on Linux.
10
11

NAME

13       pause — suspend the thread until a signal is received
14

SYNOPSIS

16       #include <unistd.h>
17
18       int pause(void);
19

DESCRIPTION

21       The pause() function shall suspend the calling thread until delivery of
22       a  signal  whose action is either to execute a signal-catching function
23       or to terminate the process.
24
25       If the action is to terminate the process, pause() shall not return.
26
27       If the action is to execute a signal-catching function,  pause()  shall
28       return after the signal-catching function returns.
29

RETURN VALUE

31       Since pause() suspends thread execution indefinitely unless interrupted
32       by a signal, there is no successful completion return value. A value of
33       −1 shall be returned and errno set to indicate the error.
34

ERRORS

36       The pause() function shall fail if:
37
38       EINTR  A  signal  is  caught  by  the  calling  process  and control is
39              returned from the signal-catching function.
40
41       The following sections are informative.
42

EXAMPLES

44       None.
45

APPLICATION USAGE

47       Many common uses of pause() have timing windows. The scenario  involves
48       checking  a  condition  related  to a signal and, if the signal has not
49       occurred, calling pause().  When the signal occurs  between  the  check
50       and  the  call  to  pause(), the process often blocks indefinitely. The
51       sigprocmask() and sigsuspend() functions can be used to avoid this type
52       of problem.
53

RATIONALE

55       None.
56

FUTURE DIRECTIONS

58       None.
59

SEE ALSO

61       sigsuspend()
62
63       The Base Definitions volume of POSIX.1‐2008, <unistd.h>
64
66       Portions  of  this text are reprinted and reproduced in electronic form
67       from IEEE Std 1003.1, 2013 Edition, Standard for Information Technology
68       --  Portable  Operating  System  Interface (POSIX), The Open Group Base
69       Specifications Issue 7, Copyright (C) 2013 by the Institute of Electri‐
70       cal  and  Electronics  Engineers,  Inc  and  The  Open Group.  (This is
71       POSIX.1-2008 with the 2013 Technical Corrigendum  1  applied.)  In  the
72       event of any discrepancy between this version and the original IEEE and
73       The Open Group Standard, the original IEEE and The Open Group  Standard
74       is  the  referee document. The original Standard can be obtained online
75       at http://www.unix.org/online.html .
76
77       Any typographical or formatting errors that appear  in  this  page  are
78       most likely to have been introduced during the conversion of the source
79       files to man page format. To report such errors,  see  https://www.ker
80       nel.org/doc/man-pages/reporting_bugs.html .
81
82
83
84IEEE/The Open Group                  2013                            PAUSE(3P)
Impressum