mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-15 19:16:40 +01:00
SystemExec try SIGINT before SIGKILL
Even though SIGINT is intended to be sent from terminals only, it is more successful at terminating various child processes than closing stdin and sending SIGTERM.
This commit is contained in:
parent
f85b4fef15
commit
18474d89f8
1 changed files with 7 additions and 0 deletions
|
|
@ -682,6 +682,13 @@ SystemExec::terminate ()
|
|||
wait(WNOHANG);
|
||||
}
|
||||
|
||||
if (pid) {
|
||||
::kill(pid, SIGINT);
|
||||
::usleep(250000);
|
||||
sched_yield();
|
||||
wait(WNOHANG);
|
||||
}
|
||||
|
||||
/* if pid is non-zero, the child task is STILL executing after being
|
||||
* sent SIGTERM. Act tough ... send SIGKILL
|
||||
*/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue