Skip to content

Commit 3c2b377

Browse files
committed
unix/unix_mphal: Just consistently set sigaction.sa_flags to 0.
1 parent 2fe7e6b commit 3c2b377

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

unix/unix_mphal.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ void mp_hal_set_interrupt_char(char c) {
5353
#ifndef _WIN32
5454
// enable signal handler
5555
struct sigaction sa;
56-
memset(&sa, 0, sizeof(sa));
56+
sa.sa_flags = 0;
5757
sa.sa_handler = sighandler;
5858
sigemptyset(&sa.sa_mask);
5959
sigaction(SIGINT, &sa, NULL);
@@ -62,6 +62,7 @@ void mp_hal_set_interrupt_char(char c) {
6262
#ifndef _WIN32
6363
// disable signal handler
6464
struct sigaction sa;
65+
sa.sa_flags = 0;
6566
sa.sa_handler = SIG_DFL;
6667
sigemptyset(&sa.sa_mask);
6768
sigaction(SIGINT, &sa, NULL);

0 commit comments

Comments
 (0)