Diff

net/server_event.lua @ 6791:e813e8cf6046

Merge 0.10->trunk
author Kim Alvefur <zash@zash.se>
date Thu, 20 Aug 2015 13:05:22 +0200
parent 6481:dbc72cd1332e
parent 6782:ec172dbe9d14
child 6820:40d50c239564
line wrap: on
line diff
--- a/net/server_event.lua	Mon Aug 17 01:58:53 2015 +0200
+++ b/net/server_event.lua	Thu Aug 20 13:05:22 2015 +0200
@@ -758,18 +758,18 @@
 		local create = socket[typ or "tcp"]
 		if type( create ) ~= "function"  then
 			return nil, "invalid socket type"
-		end
+			end
 		local client, err = create()  -- creating new socket
 		if not client then
 			debug( "cannot create socket:", err )
-			return nil, err
-		end
+				return nil, err
+			end
 		client:settimeout( 0 )  -- set nonblocking
 		local res, err = client:connect( addr, serverport )  -- connect
 		if res or ( err == "timeout" or err == "Operation already in progress" ) then
 			if client.getsockname then
 				addr = client:getsockname( )
-			end
+		end
 			local interface = wrapclient( client, addr, serverport, listener, pattern, sslctx )
 			debug( "new connection id:", interface.id )
 			return interface, err