aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorNathan Rajlich <nathan@tootallnate.net>2012-04-30 18:51:20 -0700
committerNathan Rajlich <nathan@tootallnate.net>2012-04-30 18:51:20 -0700
commitf4403f90f846f401cf93ba17cbb6f5ddde8fb03d (patch)
tree021ea7f5dbb2c1fb3560511291d5f1a21c24b3db /lib
parent6cacb9a21ee8f6f03d5e8dddc421522b7e33d5f2 (diff)
downloadandroid-node-v8-f4403f90f846f401cf93ba17cbb6f5ddde8fb03d.tar.gz
android-node-v8-f4403f90f846f401cf93ba17cbb6f5ddde8fb03d.tar.bz2
android-node-v8-f4403f90f846f401cf93ba17cbb6f5ddde8fb03d.zip
tty: emit "error" instead of throwing when getWindowSize() fails
Diffstat (limited to 'lib')
-rw-r--r--lib/tty.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/tty.js b/lib/tty.js
index 72dd88d2bf..2d66abc407 100644
--- a/lib/tty.js
+++ b/lib/tty.js
@@ -101,7 +101,7 @@ WriteStream.prototype._refreshSize = function() {
var oldRows = this.rows;
var winSize = this._handle.getWindowSize();
if (!winSize) {
- throw errnoException(errno, 'getWindowSize');
+ this.emit('error', errnoException(errno, 'getWindowSize'));
}
var newCols = winSize[0];
var newRows = winSize[1];