remove useless kill

This commit is contained in:
Thomas Hobson 2021-04-26 03:15:49 +12:00
parent 349beeb45a
commit 3b0f2a0013
No known key found for this signature in database
GPG Key ID: 9F1FD9D87950DB6F
1 changed files with 1 additions and 7 deletions

View File

@ -100,6 +100,7 @@ class Job {
proc.stdin.write(this.stdin);
proc.stdin.end();
proc.stdin.destroy();
const kill_timeout = set_timeout(_ => proc.kill('SIGKILL'), timeout);
@ -126,13 +127,6 @@ class Job {
proc.stderr.destroy();
proc.stdout.destroy();
try {
process.kill(-proc.pid, 'SIGKILL');
} catch(e) {
logger.warn(e)
// Process will be dead already, so nothing to kill.
}
};
proc.on('exit', (code, signal)=>{