Clean up Windows readline-SIGINT support

This commit is contained in:
Andrew Stewart 2014-03-03 14:35:32 -08:00
parent d8de60a02d
commit 89f0e43570
1 changed files with 4 additions and 7 deletions

View File

@ -24,7 +24,6 @@ var Cylon = (function() {
var instance = null;
// Public: Fetches singleton instance of Master, or creates a new one if it
// doesn't already exist
//
@ -49,14 +48,12 @@ var Cylon = (function() {
this.self = this;
if (process.platform === "win32") {
var readline = require("readline");
var readline = require("readline"),
io = { input: process.stdin, output: process.stdout }
var rl = readline.createInterface({
input: process.stdin,
output: process.stdout
readline.createInterface(io).on("SIGINT", function() {
process.emit("SIGINT");
});
rl.on("SIGINT", function() { return process.emit("SIGINT"); });
}
process.on("SIGINT", function() {