Skip to content

Commit

Permalink
exceptor: Add SA_ONSTACK only if available
Browse files Browse the repository at this point in the history
Notably, QNX 6.x doesn't have this flag defined.
  • Loading branch information
asabil committed May 24, 2024
1 parent bf62a36 commit 04f3fbd
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion gum/backend-posix/gumexceptor-posix.c
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,10 @@ gum_exceptor_backend_attach (GumExceptorBackend * self)

action.sa_sigaction = gum_exceptor_backend_on_signal;
sigemptyset (&action.sa_mask);
action.sa_flags = SA_SIGINFO | SA_NODEFER | SA_ONSTACK;
action.sa_flags = SA_SIGINFO | SA_NODEFER;
#ifdef SA_ONSTACK
action.sa_flags |= SA_ONSTACK;
#endif
for (i = 0; i != G_N_ELEMENTS (handled_signals); i++)
{
gint sig = handled_signals[i];
Expand Down

0 comments on commit 04f3fbd

Please sign in to comment.