Skip to content

Commit

Permalink
child_process: remove redundant condition
Browse files Browse the repository at this point in the history
There is no need to check `flowing` since `resume` does
nothing when `flowing` is already true.

PR-URL: #511
Reviewed-By: Chris Dickinson <[email protected]>
  • Loading branch information
vkurchatkin committed Jan 24, 2015
1 parent 06cfff9 commit 301a968
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lib/child_process.js
Original file line number Diff line number Diff line change
Expand Up @@ -1057,8 +1057,7 @@ util.inherits(ChildProcess, EventEmitter);
function flushStdio(subprocess) {
if (subprocess.stdio == null) return;
subprocess.stdio.forEach(function(stream, fd, stdio) {
if (!stream || !stream.readable || stream._consuming ||
stream._readableState.flowing)
if (!stream || !stream.readable || stream._consuming)
return;
stream.resume();
});
Expand Down

0 comments on commit 301a968

Please sign in to comment.