mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2026-03-09 09:01:51 +01:00
MINOR: signal: don't block SIGPROF by default
SIGPROF is blocked then restored to default settings, which sometimes makes profiling harder. Let's not block it by default nor restore it, it doesn't serve any purpose anyway.
This commit is contained in:
parent
116eefed8f
commit
6747e27667
@ -106,6 +106,7 @@ int signal_init()
|
||||
memset(signal_queue, 0, sizeof(signal_queue));
|
||||
memset(signal_state, 0, sizeof(signal_state));
|
||||
sigfillset(&blocked_sig);
|
||||
sigdelset(&blocked_sig, SIGPROF);
|
||||
for (sig = 0; sig < MAX_SIGNAL; sig++)
|
||||
LIST_INIT(&signal_state[sig].handlers);
|
||||
|
||||
@ -120,7 +121,8 @@ void deinit_signals()
|
||||
struct sig_handler *sh, *shb;
|
||||
|
||||
for (sig = 0; sig < MAX_SIGNAL; sig++) {
|
||||
signal(sig, SIG_DFL);
|
||||
if (sig != SIGPROF)
|
||||
signal(sig, SIG_DFL);
|
||||
list_for_each_entry_safe(sh, shb, &signal_state[sig].handlers, list) {
|
||||
LIST_DEL(&sh->list);
|
||||
pool_free2(pool2_sig_handlers, sh);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user