Merge pull request #2891 from hwangcc23/init-sigaction

Properly initialize sigaction struct
This commit is contained in:
Ingo Bürk 2017-09-04 18:44:14 +02:00 committed by GitHub
commit a5b5eef6c0
1 changed files with 2 additions and 0 deletions

View File

@ -305,6 +305,8 @@ void handle_signal(int sig, siginfo_t *info, void *data) {
struct sigaction action; struct sigaction action;
action.sa_handler = SIG_DFL; action.sa_handler = SIG_DFL;
action.sa_flags = 0;
sigemptyset(&action.sa_mask);
sigaction(sig, &action, NULL); sigaction(sig, &action, NULL);
raised_signal = sig; raised_signal = sig;