Fix "Error: write after end" and removed @bug tags

https://nodejs.org/api/child_process.html#child_process_event_exit
Note that when the 'exit' event is triggered, child process stdio streams might still be open.
This commit is contained in:
Michael Krasnyk
2016-09-20 20:39:55 +02:00
parent 7d124ce54d
commit 3eac6effbb
3 changed files with 11 additions and 12 deletions
+1 -1
View File
@@ -44,7 +44,7 @@ module.exports = function () {
// with lots of log output
let child = child_process.execFile(cmd, opts, {maxBuffer: 1024 * 1024 * 1000, env: env}, callback);
child.on('exit', function(code) {
log.end(util.format('*** %s exited with code %d\n', bin, code));
log.write(util.format('*** %s exited with code %d\n', bin, code));
}.bind(this));
this.setupOutputLog(child, log);
return child;