Otherwise (especially with stdin) you sometimes end up in cases
where the high water mark is zero, and the current buffer is at 0,
and it doesn't need a readable event, so it never calls _read().
}
// Setup input/output streams
- stdin = stdin || process.openStdin();
+ stdin = stdin || process.stdin;
stdout = stdout || process.stdout;
var args = ['--debug-brk'].concat(argv),
// If the user uses them, then switch into old mode.
Readable.prototype.resume = function() {
emitDataEvents(this);
+ this.read(0);
};
Readable.prototype.pause = function() {
process.nextTick(function() {
stream.emit('readable');
});
+ else
+ this.read(0);
};
// now make it start, just in case it hadn't already.