minor optimization
This commit is contained in:
parent
05cb157cfc
commit
643b5a62ea
|
@ -154,7 +154,8 @@ function applyConfig(config) {
|
|||
state.tcp[port].listen(port, function () {
|
||||
console.log('listening plain TCP on ' + port);
|
||||
});
|
||||
state.tcp[port].on('connection', function (conn) { netConnHandlers.tcp(conn, port); });
|
||||
//state.tcp[port].on('connection', function (conn) { netConnHandlers.tcp(conn, port); });
|
||||
state.tcp[port].on('connection', netConnHandlers.tcp);
|
||||
});
|
||||
//});
|
||||
}
|
||||
|
|
|
@ -54,7 +54,7 @@ module.exports.createTcpConnectionHandler = function (copts) {
|
|||
var Devices = copts.Devices;
|
||||
|
||||
return function onTcpConnection(conn, serviceport) {
|
||||
console.log('[new conn] from port', serviceport);
|
||||
serviceport = serviceport || conn.localPort;
|
||||
// this works when I put it here, but I don't know if it's tls yet here
|
||||
// httpsServer.emit('connection', socket);
|
||||
//tls3000.emit('connection', socket);
|
||||
|
|
Loading…
Reference in New Issue