Bug 777939: Add missing onStopListening for the REPL socket listener. r=vingtetun

This commit is contained in:
Marshall Culpepper 2012-07-27 11:19:56 -05:00
parent b2da18e471
commit c4f893f231

View File

@ -400,6 +400,11 @@ Services.obs.addObserver(function onSystemMessage(subject, topic, data) {
output = clientSocket.openOutputStream(Ci.nsITransport.OPEN_BLOCKING, 0, 0); output = clientSocket.openOutputStream(Ci.nsITransport.OPEN_BLOCKING, 0, 0);
output.write(prompt, prompt.length); output.write(prompt, prompt.length);
input.asyncWait(reader, 0, 0, Services.tm.mainThread); input.asyncWait(reader, 0, 0, Services.tm.mainThread);
},
onStopListening: function repl_onStopListening() {
if (output) {
output.close();
}
} }
} }
let serverPort = Services.prefs.getIntPref('b2g.remote-js.port'); let serverPort = Services.prefs.getIntPref('b2g.remote-js.port');