[ Bottom of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]

Technical Reference: Base Operating System and Extensions, Volume 2

sigsetjmp or siglongjmp Subroutine

Purpose

Saves or restores stack context and signal mask.

Library

Standard C Library (libc.a)

Syntax

#include <setjmp.h>


int sigsetjmp ( Environment, SaveMask)
sigjmp_buf Environment;
int SaveMask;


void siglongjmp (Environment, Value)
sigjmp_buf Environment;
int Value;

Description

The sigsetjmp subroutine saves the current stack context, and if the value of the SaveMask parameter is not 0, the sigsetjmp subroutine also saves the current signal mask of the process as part of the calling environment.

The siglongjmp subroutine restores the saved signal mask only if the Environment parameter was initialized by a call to the sigsetjmp subroutine with a nonzero SaveMask parameter argument.

Parameters

Environment Specifies an address for a sigjmp_buf structure.
SaveMask Specifies the flag used to determine if the signal mask is to be saved.
Value Specifies the return value from the siglongjmp subroutine.

Return Values

The sigsetjmp subroutine returns a value of 0. The siglongjmp subroutine returns a nonzero value.

Related Information

The setjmp or longjmp (setjmp or longjmp Subroutine) subroutine, sigaction (sigaction, sigvec, or signal Subroutine) subroutine, sigprocmask (sigprocmask, sigsetmask, or sigblock Subroutine) subroutine, sigsuspend (sigsuspend or sigpause Subroutine) subroutine.

[ Top of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]