… | |
… | |
2585 | if (!((WL)w)->next) |
2585 | if (!((WL)w)->next) |
2586 | { |
2586 | { |
2587 | #if _WIN32 |
2587 | #if _WIN32 |
2588 | signal (w->signum, ev_sighandler); |
2588 | signal (w->signum, ev_sighandler); |
2589 | #else |
2589 | #else |
2590 | struct sigaction sa; |
2590 | struct sigaction sa = { }; |
2591 | sa.sa_handler = ev_sighandler; |
2591 | sa.sa_handler = ev_sighandler; |
2592 | sigfillset (&sa.sa_mask); |
2592 | sigfillset (&sa.sa_mask); |
2593 | sa.sa_flags = SA_RESTART; /* if restarting works we save one iteration */ |
2593 | sa.sa_flags = SA_RESTART; /* if restarting works we save one iteration */ |
2594 | sigaction (w->signum, &sa, 0); |
2594 | sigaction (w->signum, &sa, 0); |
2595 | #endif |
2595 | #endif |