[Bug nptl/22563] New: __cancel_jmp_buf in __pthread_unwind_buf_t is incompatible with setjmp/longmp
hjl.tools at gmail dot com
sourceware-bugzilla@sourceware.org
Wed Dec 6 22:43:00 GMT 2017
https://sourceware.org/bugzilla/show_bug.cgi?id=22563
Bug ID: 22563
Summary: __cancel_jmp_buf in __pthread_unwind_buf_t is
incompatible with setjmp/longmp
Product: glibc
Version: 2.27
Status: NEW
Severity: normal
Priority: P2
Component: nptl
Assignee: unassigned at sourceware dot org
Reporter: hjl.tools at gmail dot com
CC: drepper.fsp at gmail dot com
Target Milestone: ---
sysdeps/nptl/pthread.h has
/* Cancellation handling with integration into exception handling. */
typedef struct
{
struct
{
__jmp_buf __cancel_jmp_buf;
int __mask_was_saved;
} __cancel_jmp_buf[1];
void *__pad[4];
} __pthread_unwind_buf_t __attribute__ ((__aligned__));
But setjmp/setjmp.h has
/* Calling environment, plus possibly a saved signal mask. */
struct __jmp_buf_tag
{
/* NOTE: The machine-dependent definitions of `__sigsetjmp'
assume that a `jmp_buf' begins with a `__jmp_buf' and that
`__mask_was_saved' follows it. Do not move these members
or add others before it. */
__jmp_buf __jmpbuf; /* Calling environment. */
int __mask_was_saved; /* Saved the signal mask? */
__sigset_t __saved_mask; /* Saved signal mask. */
};
__sigset_t is missing from __cancel_jmp_buf.
--
You are receiving this mail because:
You are on the CC list for the bug.
More information about the Glibc-bugs
mailing list