aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2009-07-12 14:29:42 +0100
committerMatthew Wild <mwild1@gmail.com>2009-07-12 14:29:42 +0100
commit4273b66a6ca55288d83f66203d51a2287eea16aa (patch)
tree92f4e6cbf73b6ef04acc4559de3e2f4cced3b48a
parent368d427f1a57002ca51e3c05ba3c4f3011876832 (diff)
downloadprosody-4273b66a6ca55288d83f66203d51a2287eea16aa.tar.gz
prosody-4273b66a6ca55288d83f66203d51a2287eea16aa.zip
net.server: Don't close handler if it is already nil when SSL handshake fails
-rw-r--r--net/server.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/server.lua b/net/server.lua
index ca6e6380..9418d388 100644
--- a/net/server.lua
+++ b/net/server.lua
@@ -530,7 +530,7 @@ wrapconnection = function( server, listeners, socket, ip, serverport, clientport
end
end
disconnect( handler, "ssl handshake failed" )
- handler.close( true ) -- forced disconnect
+ _ = handler and handler.close( true ) -- forced disconnect
return false -- handshake failed
end
)