diff options
author | crupest <crupest@outlook.com> | 2023-02-06 00:14:55 +0800 |
---|---|---|
committer | crupest <crupest@outlook.com> | 2023-02-06 00:14:55 +0800 |
commit | 1325a030509f252ba77c1b6787c18d774513bac0 (patch) | |
tree | ff99a839d5af3cb657a57cae953891b3a173d13f /works/life | |
parent | a207604826d5b4eb1a230adc2c201fdc478b2678 (diff) | |
download | crupest-1325a030509f252ba77c1b6787c18d774513bac0.tar.gz crupest-1325a030509f252ba77c1b6787c18d774513bac0.tar.bz2 crupest-1325a030509f252ba77c1b6787c18d774513bac0.zip |
import(life): Fix linux run bug.
Diffstat (limited to 'works/life')
-rw-r--r-- | works/life/linux-run/linux-run.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/works/life/linux-run/linux-run.cpp b/works/life/linux-run/linux-run.cpp index e656e55..dcb9944 100644 --- a/works/life/linux-run/linux-run.cpp +++ b/works/life/linux-run/linux-run.cpp @@ -131,6 +131,7 @@ void run(const std::string &program, std::vector<std::string> arguments, int poll_return = poll(&sigchld_poll, 1, timeout_value); if (poll_return == 0) { + kill(pid, SIGKILL); throw TimeoutError("Timeout to run command."); } else if (poll_return == -1) { if (errno == EINTR) { |