mirror of
https://github.com/nodejs/node.git
synced 2026-10-14 10:26:26 -04:00
src: nix stdin _readableState.reading manipulation
this opts for stream.push('') which has the same effect
but uses a public API.
PR-URL: https://github.com/nodejs/io.js/pull/454
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com>
This commit is contained in:
1 parent
7f63449fde
commit
8cee8f54fc
1 file changed
+2
-2
+2
-2
@@ -699,7 +699,7 @@
|
||||
// not-reading state.
|
||||
if (stdin._handle && stdin._handle.readStop) {
|
||||
stdin._handle.reading = false;
|
||||
stdin._readableState.reading = false;
|
||||
stdin.push('');
|
||||
stdin._handle.readStop();
|
||||
}
|
||||
|
||||
@@ -708,7 +708,7 @@
|
||||
stdin.on('pause', function() {
|
||||
if (!stdin._handle)
|
||||
return;
|
||||
stdin._readableState.reading = false;
|
||||
stdin.push('');
|
||||
stdin._handle.reading = false;
|
||||
stdin._handle.readStop();
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user