# define SIGACTION_WORKS 1
#else
# define SIGACTION_WORKS 0
+# ifndef SA_ONSTACK
+# define SA_ONSTACK 0
+# endif
#endif
extern char *program_name;
act.sa_flags = SA_NODEFER | SA_ONSTACK | SA_RESETHAND | SA_SIGINFO;
act.sa_sigaction = segv_handler;
# else
- act.sa_flags = SA_NODEFER | SA_RESETHAND;
+ act.sa_flags = SA_NODEFER | SA_ONSTACK | SA_RESETHAND;
act.sa_handler = die;
# endif