
#include <lcsignal.h> int sigaddset(sigset_t *set, int signum); int sigdelset(sigset_t *set, int signum); int sigemptyset(sigset_t *set); int sigfillset(sigset_t *set); int sigismember(const sigset_t *set, int signum);For the POSIX implementation, include the header file
<signal.h> after defining an appropriate feature
test macro.
sigaddset, sigdelset, sigemptyset,
sigfillset, and sigismember enable you to modify the
sigset_t object addressed by set. The sigset_t
function is
defined in <signal.h> and <lcsignal.h> as a type
representing a collection of signal numbers. Signal sets are passed
as arguments to other signal handling functions, such as
sigprocmask, sigpending, and oesigsetup.
The functions that modify signals in a set of signals include
sigaddset
signum to the set.
sigdelset
signum from the set.
sigemptyset
sigfillset
sigismember
signum is a member of the set.
sigismember returns 1 if signum is a member of the set,
or 0 if it is not in the set. All other functions return 0 if successful.
All functions return - 1 if an error occurs (such as an invalid signal
number).
oesigsetup. The call to oesigsetup defines SIGALRM and
SIGFPE as signals managed by SAS/C, and all others as
signals managed by OpenEdition. See the sigpending example for
an example using sigismember.
#include <lcsignal.h> sigset_t sascset, oeset; sigemptyset(&sascset); sigaddset(&sascset, SIGFPE); /* SAS/C will manage SIGALRM and SIGFPE. */ sigaddset(&sascser, SIGALRM); sigfillset(&oeset); sigdelset(&oeset, SIGFPE); /* OpenEdition manages everything else */ /* (whenever possible). */ sigdelset(&oeset, SIGALRM); oesigsetup(&oeset, &sascset);
Copyright (c) 1998 SAS Institute Inc. Cary, NC, USA. All rights reserved.