fix: always close file handles to stdout/stderr logs (#259)
This commit is contained in:
Родитель
f1baa9af20
Коммит
f9e436934b
|
@ -415,16 +415,16 @@ class Launcher {
|
|||
}
|
||||
|
||||
destroyTmp() {
|
||||
// Only clean up the tmp dir if we created it.
|
||||
if (this.userDataDir === undefined || this.opts.userDataDir !== undefined) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.outFile) {
|
||||
this.fs.closeSync(this.outFile);
|
||||
delete this.outFile;
|
||||
}
|
||||
|
||||
// Only clean up the tmp dir if we created it.
|
||||
if (this.userDataDir === undefined || this.opts.userDataDir !== undefined) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.errFile) {
|
||||
this.fs.closeSync(this.errFile);
|
||||
delete this.errFile;
|
||||
|
|
Загрузка…
Ссылка в новой задаче