If a signal handler runs during select() loop in clixon_event_loop() and unless the signal handler sets clixon_exit, the select will be restarted.
This commit is contained in:
parent
c509868345
commit
d5edd64257
5 changed files with 40 additions and 5 deletions
|
|
@ -68,7 +68,7 @@ set_signal(int signo,
|
|||
|
||||
snew.sa_handler = handler;
|
||||
sigemptyset(&snew.sa_mask);
|
||||
snew.sa_flags = 0;
|
||||
snew.sa_flags = SA_RESTART;
|
||||
if (sigaction(signo, &snew, &sold) < 0){
|
||||
clicon_err(OE_UNIX, errno, "sigaction");
|
||||
return -1;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue