|
Packit |
7cfc04 |
'\" et
|
|
Packit |
7cfc04 |
.TH SIGEMPTYSET "3P" 2013 "IEEE/The Open Group" "POSIX Programmer's Manual"
|
|
Packit |
7cfc04 |
.SH PROLOG
|
|
Packit |
7cfc04 |
This manual page is part of the POSIX Programmer's Manual.
|
|
Packit |
7cfc04 |
The Linux implementation of this interface may differ (consult
|
|
Packit |
7cfc04 |
the corresponding Linux manual page for details of Linux behavior),
|
|
Packit |
7cfc04 |
or the interface may not be implemented on Linux.
|
|
Packit |
7cfc04 |
|
|
Packit |
7cfc04 |
.SH NAME
|
|
Packit |
7cfc04 |
sigemptyset
|
|
Packit |
7cfc04 |
\(em initialize and empty a signal set
|
|
Packit |
7cfc04 |
.SH SYNOPSIS
|
|
Packit |
7cfc04 |
.LP
|
|
Packit |
7cfc04 |
.nf
|
|
Packit |
7cfc04 |
#include <signal.h>
|
|
Packit |
7cfc04 |
.P
|
|
Packit |
7cfc04 |
int sigemptyset(sigset_t *\fIset\fP);
|
|
Packit |
7cfc04 |
.fi
|
|
Packit |
7cfc04 |
.SH DESCRIPTION
|
|
Packit |
7cfc04 |
The
|
|
Packit |
7cfc04 |
\fIsigemptyset\fR()
|
|
Packit |
7cfc04 |
function initializes the signal set pointed to by
|
|
Packit |
7cfc04 |
.IR set ,
|
|
Packit |
7cfc04 |
such that all signals defined in POSIX.1\(hy2008 are excluded.
|
|
Packit |
7cfc04 |
.SH "RETURN VALUE"
|
|
Packit |
7cfc04 |
Upon successful completion,
|
|
Packit |
7cfc04 |
\fIsigemptyset\fR()
|
|
Packit |
7cfc04 |
shall return 0; otherwise, it shall return \(mi1 and set
|
|
Packit |
7cfc04 |
.IR errno
|
|
Packit |
7cfc04 |
to indicate the error.
|
|
Packit |
7cfc04 |
.SH ERRORS
|
|
Packit |
7cfc04 |
No errors are defined.
|
|
Packit |
7cfc04 |
.LP
|
|
Packit |
7cfc04 |
.IR "The following sections are informative."
|
|
Packit |
7cfc04 |
.SH EXAMPLES
|
|
Packit |
7cfc04 |
None.
|
|
Packit |
7cfc04 |
.SH "APPLICATION USAGE"
|
|
Packit |
7cfc04 |
None.
|
|
Packit |
7cfc04 |
.SH RATIONALE
|
|
Packit |
7cfc04 |
The implementation of the
|
|
Packit |
7cfc04 |
\fIsigemptyset\fR()
|
|
Packit |
7cfc04 |
(or
|
|
Packit |
7cfc04 |
\fIsigfillset\fR())
|
|
Packit |
7cfc04 |
function could quite trivially clear (or set) all the bits in the
|
|
Packit |
7cfc04 |
signal set. Alternatively, it would be reasonable to initialize part
|
|
Packit |
7cfc04 |
of the structure, such as a version field, to permit
|
|
Packit |
7cfc04 |
binary-compatibility between releases where the size of the set
|
|
Packit |
7cfc04 |
varies. For such reasons, either
|
|
Packit |
7cfc04 |
\fIsigemptyset\fR()
|
|
Packit |
7cfc04 |
or
|
|
Packit |
7cfc04 |
\fIsigfillset\fR()
|
|
Packit |
7cfc04 |
must be called prior to any other use of the signal set, even if such
|
|
Packit |
7cfc04 |
use is read-only (for example, as an argument to
|
|
Packit |
7cfc04 |
\fIsigpending\fR()).
|
|
Packit |
7cfc04 |
This function is not intended for dynamic allocation.
|
|
Packit |
7cfc04 |
.P
|
|
Packit |
7cfc04 |
The
|
|
Packit |
7cfc04 |
\fIsigfillset\fR()
|
|
Packit |
7cfc04 |
and
|
|
Packit |
7cfc04 |
\fIsigemptyset\fR()
|
|
Packit |
7cfc04 |
functions require that the resulting signal set include (or exclude)
|
|
Packit |
7cfc04 |
all the signals defined in this volume of POSIX.1\(hy2008. Although it is outside the scope of
|
|
Packit |
7cfc04 |
\&this volume of POSIX.1\(hy2008 to place this requirement on signals that are implemented as
|
|
Packit |
7cfc04 |
extensions, it is recommended that implementation-defined signals
|
|
Packit |
7cfc04 |
also be affected by these functions. However, there may be a good
|
|
Packit |
7cfc04 |
reason for a particular signal not to be affected. For example,
|
|
Packit |
7cfc04 |
blocking or ignoring an implementation-defined signal may have
|
|
Packit |
7cfc04 |
undesirable side-effects, whereas the default action for that signal is
|
|
Packit |
7cfc04 |
harmless. In such a case, it would be preferable for such a signal to
|
|
Packit |
7cfc04 |
be excluded from the signal set returned by
|
|
Packit |
7cfc04 |
\fIsigfillset\fR().
|
|
Packit |
7cfc04 |
.P
|
|
Packit |
7cfc04 |
In early proposals there was no distinction between invalid and
|
|
Packit |
7cfc04 |
unsupported signals (the names of optional signals that were not
|
|
Packit |
7cfc04 |
supported by an implementation were not defined by that
|
|
Packit |
7cfc04 |
implementation). The
|
|
Packit |
7cfc04 |
.BR [EINVAL]
|
|
Packit |
7cfc04 |
error was thus specified as a required error for invalid signals. With
|
|
Packit |
7cfc04 |
that distinction, it is not necessary to require implementations of
|
|
Packit |
7cfc04 |
these functions to determine whether an optional signal is actually
|
|
Packit |
7cfc04 |
supported, as that could have a significant performance impact for
|
|
Packit |
7cfc04 |
little value. The error could have been required for invalid signals
|
|
Packit |
7cfc04 |
and optional for unsupported signals, but this seemed unnecessarily
|
|
Packit |
7cfc04 |
complex. Thus, the error is optional in both cases.
|
|
Packit |
7cfc04 |
.SH "FUTURE DIRECTIONS"
|
|
Packit |
7cfc04 |
None.
|
|
Packit |
7cfc04 |
.SH "SEE ALSO"
|
|
Packit |
7cfc04 |
.ad l
|
|
Packit |
7cfc04 |
.IR "Section 2.4" ", " "Signal Concepts",
|
|
Packit |
7cfc04 |
.IR "\fIpthread_sigmask\fR\^(\|)",
|
|
Packit |
7cfc04 |
.IR "\fIsigaction\fR\^(\|)",
|
|
Packit |
7cfc04 |
.IR "\fIsigaddset\fR\^(\|)",
|
|
Packit |
7cfc04 |
.IR "\fIsigdelset\fR\^(\|)",
|
|
Packit |
7cfc04 |
.IR "\fIsigfillset\fR\^(\|)",
|
|
Packit |
7cfc04 |
.IR "\fIsigismember\fR\^(\|)",
|
|
Packit |
7cfc04 |
.IR "\fIsigpending\fR\^(\|)",
|
|
Packit |
7cfc04 |
.IR "\fIsigsuspend\fR\^(\|)"
|
|
Packit |
7cfc04 |
.ad b
|
|
Packit |
7cfc04 |
.P
|
|
Packit |
7cfc04 |
The Base Definitions volume of POSIX.1\(hy2008,
|
|
Packit |
7cfc04 |
.IR "\fB<signal.h>\fP"
|
|
Packit |
7cfc04 |
.SH COPYRIGHT
|
|
Packit |
7cfc04 |
Portions of this text are reprinted and reproduced in electronic form
|
|
Packit |
7cfc04 |
from IEEE Std 1003.1, 2013 Edition, Standard for Information Technology
|
|
Packit |
7cfc04 |
-- Portable Operating System Interface (POSIX), The Open Group Base
|
|
Packit |
7cfc04 |
Specifications Issue 7, Copyright (C) 2013 by the Institute of
|
|
Packit |
7cfc04 |
Electrical and Electronics Engineers, Inc and The Open Group.
|
|
Packit |
7cfc04 |
(This is POSIX.1-2008 with the 2013 Technical Corrigendum 1 applied.) In the
|
|
Packit |
7cfc04 |
event of any discrepancy between this version and the original IEEE and
|
|
Packit |
7cfc04 |
The Open Group Standard, the original IEEE and The Open Group Standard
|
|
Packit |
7cfc04 |
is the referee document. The original Standard can be obtained online at
|
|
Packit |
7cfc04 |
http://www.unix.org/online.html .
|
|
Packit |
7cfc04 |
|
|
Packit |
7cfc04 |
Any typographical or formatting errors that appear
|
|
Packit |
7cfc04 |
in this page are most likely
|
|
Packit |
7cfc04 |
to have been introduced during the conversion of the source files to
|
|
Packit |
7cfc04 |
man page format. To report such errors, see
|
|
Packit |
7cfc04 |
https://www.kernel.org/doc/man-pages/reporting_bugs.html .
|