charon-cmd: Block SIGUSR1 on worker threads
To properly shut down charon-cmd with leak reports, only the main thread should catch SIGUSR1 to shut down the application. Work threads should ignore SIGUSR1 to avoid any hard application termination.
This commit is contained in:
1 parent
0edd13b6c8
commit
1df1430146
1 file changed
+1
@@ -389,6 +389,7 @@ int main(int argc, char *argv[])
|
||||
sigaddset(&action.sa_mask, SIGINT);
|
||||
sigaddset(&action.sa_mask, SIGTERM);
|
||||
sigaddset(&action.sa_mask, SIGHUP);
|
||||
sigaddset(&action.sa_mask, SIGUSR1);
|
||||
sigaction(SIGSEGV, &action, NULL);
|
||||
sigaction(SIGILL, &action, NULL);
|
||||
sigaction(SIGBUS, &action, NULL);
|
||||
|
||||
Reference in new issue
Block a user