From 3606c59339ea6f515165e09a3a5f85e3665595e6 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Fri, 6 Sep 2013 10:53:04 +0200 Subject: net.server_select: Return handler from addclient --- net/server_select.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'net') diff --git a/net/server_select.lua b/net/server_select.lua index d5d27206..ca55d2d5 100644 --- a/net/server_select.lua +++ b/net/server_select.lua @@ -937,9 +937,9 @@ local addclient = function( address, port, listeners, pattern, sslctx ) client:settimeout( 0 ) _, err = client:connect( address, port ) if err then -- try again - local handler = wrapclient( client, address, port, listeners, pattern, sslctx ) + return wrapclient( client, address, port, listeners, pattern, sslctx ) else - wrapconnection( nil, listeners, client, address, port, "clientport", pattern, sslctx ) + return wrapconnection( nil, listeners, client, address, port, "clientport", pattern, sslctx ) end end -- cgit v1.2.3