From 86397e7d0622dfd3641336ecf982dff94b9c3b96 Mon Sep 17 00:00:00 2001 From: Romain Beaumont Date: Mon, 15 Feb 2016 20:50:42 +0100 Subject: [PATCH] display error in proxy --- examples/proxy/proxy.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/examples/proxy/proxy.js b/examples/proxy/proxy.js index f6091ec..3bd6e67 100644 --- a/examples/proxy/proxy.js +++ b/examples/proxy/proxy.js @@ -85,9 +85,10 @@ srv.on('login', function(client) { if(!endedTargetClient) targetClient.end("End"); }); - client.on('error', function() { + client.on('error', function(err) { endedClient = true; console.log('Connection error by client', '(' + addr + ')'); + console.log(err.stack); if(!endedTargetClient) targetClient.end("Error"); });