summaryrefslogtreecommitdiff
path: root/lib/tty.js
diff options
context:
space:
mode:
authorEvan Lucas <evanlucas@me.com>2016-03-29 08:09:37 -0500
committerEvan Lucas <evanlucas@me.com>2016-03-29 10:21:46 -0500
commitb6475b9a9d0da0971eec7eb5559dff4d18a0e721 (patch)
treeac46d328514d12081b9b98a38319e31cc2ae7fe5 /lib/tty.js
parent89abe8680864d982022d9488ce30a3182afa67ee (diff)
downloadandroid-node-v8-b6475b9a9d0da0971eec7eb5559dff4d18a0e721.tar.gz
android-node-v8-b6475b9a9d0da0971eec7eb5559dff4d18a0e721.tar.bz2
android-node-v8-b6475b9a9d0da0971eec7eb5559dff4d18a0e721.zip
Revert "tty: don't read from console stream upon creation"
This reverts commit 461138929498f31bd35bea61aa4375a2f56cceb7. The offending commit broke certain usages of piping from stdin. Fixes: https://github.com/nodejs/node/issues/5927 PR-URL: https://github.com/nodejs/node/pull/5947 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Alexis Campailla <orangemocha@nodejs.org> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Diffstat (limited to 'lib/tty.js')
-rw-r--r--lib/tty.js8
1 files changed, 1 insertions, 7 deletions
diff --git a/lib/tty.js b/lib/tty.js
index ee6c0407f6..72efcd078b 100644
--- a/lib/tty.js
+++ b/lib/tty.js
@@ -17,23 +17,17 @@ function ReadStream(fd, options) {
if (!(this instanceof ReadStream))
return new ReadStream(fd, options);
- // pauseOnCreate to avoid reading from the sytem buffer
options = util._extend({
highWaterMark: 0,
readable: true,
writable: false,
- handle: new TTY(fd, true),
- pauseOnCreate: true
+ handle: new TTY(fd, true)
}, options);
net.Socket.call(this, options);
this.isRaw = false;
this.isTTY = true;
-
- // Let the stream resume automatically when 'data' event handlers
- // are added, even though it was paused on creation
- this._readableState.flowing = null;
}
inherits(ReadStream, net.Socket);