Skip to content
This repository has been archived by the owner on Apr 22, 2023. It is now read-only.

Commit

Permalink
readline: explicitly disable and re-enable "raw mode" on Ctrl+Z
Browse files Browse the repository at this point in the history
Fixes #3295.
  • Loading branch information
TooTallNate committed May 22, 2012
1 parent 2b9967f commit 3f69c71
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/readline.js
Expand Up @@ -656,8 +656,13 @@ Interface.prototype._ttyWrite = function(s, key) {
self.pause();
self.emit('SIGCONT');
}
// explictly re-enable "raw mode" and move the cursor to the correct
// position. See https://github.com/joyent/node/issues/3295.
self._setRawMode(true);
self._refreshLine();
};
})(this));
this._setRawMode(false);
process.kill(process.pid, 'SIGTSTP');
}
break;
Expand Down

0 comments on commit 3f69c71

Please sign in to comment.