Check for process from within handleEvents

This commit is contained in:
Kevin Sawicki
2015-04-28 18:08:44 -07:00
parent 78d2c868f7
commit a9806d63eb

View File

@@ -74,7 +74,7 @@ class BufferedProcess
@spawn(command, args, options)
@killed = false
@handleEvents(stdout, stderr, exit) if @process?
@handleEvents(stdout, stderr, exit)
###
Section: Event Subscription
@@ -192,6 +192,8 @@ class BufferedProcess
process.nextTick => @handleError(spawnError)
handleEvents: (stdout, stderr, exit) ->
return unless @process?
stdoutClosed = true
stderrClosed = true
processExited = true