Browse Source

child_process: remove redundant condition

There is no need to check `flowing` since `resume` does
nothing when `flowing` is already true.

PR-URL: https://github.com/iojs/io.js/pull/511
Reviewed-By: Chris Dickinson <christopher.s.dickinson@gmail.com>
v1.8.0-commit
Vladimir Kurchatkin 10 years ago
parent
commit
301a968a40
  1. 3
      lib/child_process.js

3
lib/child_process.js

@ -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();
});

Loading…
Cancel
Save