unix/unix_mphal: Just consistently set sigaction.sa_flags to 0.

This commit is contained in:
Paul Sokolovsky 2015-12-18 01:05:12 +02:00
parent 2fe7e6bef0
commit 3c2b377711
1 changed files with 2 additions and 1 deletions

View File

@ -53,7 +53,7 @@ void mp_hal_set_interrupt_char(char c) {
#ifndef _WIN32
// enable signal handler
struct sigaction sa;
memset(&sa, 0, sizeof(sa));
sa.sa_flags = 0;
sa.sa_handler = sighandler;
sigemptyset(&sa.sa_mask);
sigaction(SIGINT, &sa, NULL);
@ -62,6 +62,7 @@ void mp_hal_set_interrupt_char(char c) {
#ifndef _WIN32
// disable signal handler
struct sigaction sa;
sa.sa_flags = 0;
sa.sa_handler = SIG_DFL;
sigemptyset(&sa.sa_mask);
sigaction(SIGINT, &sa, NULL);