Library /sys$common/syshlp/helplib.hlb  —  CRTL  sigtimedwait
    Suspends a calling thread and waits for queued signals to arrive.

    This function is supported on OpenVMS Integrity servers and
    Alpha only.

    Format

      #include  <signal.h>

      int sigtimedwait  (const sigset_t set, siginfo_t *info, const
                        struct timespec *timeout);

1  –  Arguments

 set

    The set of signals to wait for.

 info

    Pointer to a siginfo structure that is receiving data describing
    the signal, including any application-defined data specified when
    the signal was posted.

 timeout

    A timeout for the wait. If timeout is NULL, the argument is
    ignored.

2  –  Description

    The sigtimedwait function behaves the same as the sigwaitinfo
    function except that if none of the signals specified by set are
    pending, sigtimedwait waits for the time interval specified in
    the timespec structure referenced by timeout. If the timespec
    structure pointed to by timeout is zero-valued and if none of the
    signals specified by set are pending, then sigtimedwait returns
    immediately with an error.

    See also sigwait and sigwaitinfo.

    See the "Error and Signal Handling" chapter of the VSI C RTL
    Reference Manual for more information on signal handling.

3  –  Return Values

    x                  Upon successful completion, the signal number
                       selected is returned.
    -1                 Indicates that an error occurred; errno is set
                       to one of the following values:

                       o  EINVAL - The timeout argument specified a
                          tv_nsec value less than 0 or greater than
                          or equal to 1 billion.

                       o  EINTR - The wait was interrupted by an
                          unblocked, intercepted signal.

                       o  EAGAIN - No signal specified by set was
                          generated within the specified timeout
                          period.
Close Help