mirror of
https://github.com/python/cpython.git
synced 2025-11-01 18:51:43 +00:00
faulthandler: we don't use (or need) SA_SIGINFO flag of sigaction()
This commit is contained in:
parent
9699440b57
commit
44e31baf95
1 changed files with 2 additions and 7 deletions
|
|
@ -218,12 +218,7 @@ faulthandler_dump_traceback_py(PyObject *self,
|
||||||
This function is signal safe and should only call signal safe functions. */
|
This function is signal safe and should only call signal safe functions. */
|
||||||
|
|
||||||
static void
|
static void
|
||||||
faulthandler_fatal_error(
|
faulthandler_fatal_error(int signum)
|
||||||
int signum
|
|
||||||
#ifdef HAVE_SIGACTION
|
|
||||||
, siginfo_t *siginfo, void *ucontext
|
|
||||||
#endif
|
|
||||||
)
|
|
||||||
{
|
{
|
||||||
const int fd = fatal_error.fd;
|
const int fd = fatal_error.fd;
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
|
@ -320,7 +315,7 @@ faulthandler_enable(PyObject *self, PyObject *args, PyObject *kwargs)
|
||||||
for (i=0; i < faulthandler_nsignals; i++) {
|
for (i=0; i < faulthandler_nsignals; i++) {
|
||||||
handler = &faulthandler_handlers[i];
|
handler = &faulthandler_handlers[i];
|
||||||
#ifdef HAVE_SIGACTION
|
#ifdef HAVE_SIGACTION
|
||||||
action.sa_sigaction = faulthandler_fatal_error;
|
action.sa_handler = faulthandler_fatal_error;
|
||||||
sigemptyset(&action.sa_mask);
|
sigemptyset(&action.sa_mask);
|
||||||
/* Do not prevent the signal from being received from within
|
/* Do not prevent the signal from being received from within
|
||||||
its own signal handler */
|
its own signal handler */
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue