1_longjmp(3C)             Standard C Library Functions             _longjmp(3C)
2
3
4

NAME

6       _longjmp, _setjmp - non-local goto
7

SYNOPSIS

9       #include <setjmp.h>
10
11       void _longjmp(jmp_buf env, int val);
12
13
14       int _setjmp(jmp_buf env);
15
16

DESCRIPTION

18       The _longjmp() and _setjmp() functions are identical to longjmp(3C) and
19       setjmp(3C),  respectively,  with  the   additional   restriction   that
20       _longjmp() and _setjmp() do not manipulate the signal mask.
21
22
23       If _longjmp() is called even though env was never initialized by a call
24       to _setjmp(), or when the last such call was in  a  function  that  has
25       since returned, the results are undefined.
26

RETURN VALUES

28       Refer to longjmp(3C) and setjmp(3C).
29

ERRORS

31       No errors are defined.
32

USAGE

34       If  _longjmp()  is  executed and the environment in which _setjmp() was
35       executed no longer exists, errors can occur. The conditions under which
36       the  environment  of the _setjmp() no longer exists include exiting the
37       function that contains the _setjmp() call, and exiting an  inner  block
38       with  temporary  storage.  This  condition  might not be detectable, in
39       which case the _longjmp() occurs and,  if  the  environment  no  longer
40       exists,  the  contents  of  the temporary storage of an inner block are
41       unpredictable. This condition might also cause unexpected process  ter‐
42       mination. If the function has returned, the results are undefined.
43
44
45       Passing  longjmp() a pointer to a buffer not created by setjmp(), pass‐
46       ing _longjmp() a pointer to a buffer not created by _setjmp(),  passing
47       siglongjmp(3C)  a  pointer  to a buffer not created by sigsetjmp(3C) or
48       passing any of these three functions a buffer that has been modified by
49       the user can cause all the problems listed above, and more.
50
51
52       The _longjmp() and _setjmp() functions are included to support programs
53       written to historical system interfaces.  New applications  should  use
54       siglongjmp(3C) and sigsetjmp(3C) respectively.
55

ATTRIBUTES

57       See attributes(5) for descriptions of the following attributes:
58
59
60
61
62       ┌─────────────────────────────┬─────────────────────────────┐
63ATTRIBUTE TYPE               ATTRIBUTE VALUE              
64       ├─────────────────────────────┼─────────────────────────────┤
65       │Interface Stability          │Standard                     │
66       └─────────────────────────────┴─────────────────────────────┘
67

SEE ALSO

69       longjmp(3C),  setjmp(3C), siglongjmp(3C), sigsetjmp(3C), attributes(5),
70       standards(5)
71
72
73
74SunOS 5.11                        24 Jul 2002                     _longjmp(3C)
Impressum