mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-03-05 19:10:45 +00:00
BUG/MINOR: don't ignore SIG{BUS,FPE,ILL,SEGV} during signal processing
We don't have any reason of blocking those signals. If SIGBUS, SIGFPE, SIGILL, or SIGSEGV are generated while they are blocked, the result is undefined, unless the signal was generated by kill(2), sigqueue(3), or raise(3). This should be backported to 1.8.
This commit is contained in:
parent
1aab50bb4a
commit
933642c6ef
@ -120,6 +120,14 @@ int signal_init()
|
||||
|
||||
sigfillset(&blocked_sig);
|
||||
sigdelset(&blocked_sig, SIGPROF);
|
||||
/* man sigprocmask: If SIGBUS, SIGFPE, SIGILL, or SIGSEGV are
|
||||
generated while they are blocked, the result is undefined, unless
|
||||
the signal was generated by kill(2),
|
||||
sigqueue(3), or raise(3) */
|
||||
sigdelset(&blocked_sig, SIGBUS);
|
||||
sigdelset(&blocked_sig, SIGFPE);
|
||||
sigdelset(&blocked_sig, SIGILL);
|
||||
sigdelset(&blocked_sig, SIGSEGV);
|
||||
for (sig = 0; sig < MAX_SIGNAL; sig++)
|
||||
LIST_INIT(&signal_state[sig].handlers);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user