diff options
author | Matthew Wild <mwild1@gmail.com> | 2010-07-02 17:44:14 +0100 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2010-07-02 17:44:14 +0100 |
commit | f654c430081b0161e66e28c70e6da80a5da99250 (patch) | |
tree | 27fb0b62bf1c29b28376fe4ff61f372f4381bdb1 /net/server_select.lua | |
parent | 1309f761cb42ad3502fda993efaf56cb3dca3860 (diff) | |
parent | e563e751d0f7293ebd22cc9d8896c6cd041c1bf6 (diff) | |
download | prosody-f654c430081b0161e66e28c70e6da80a5da99250.tar.gz prosody-f654c430081b0161e66e28c70e6da80a5da99250.zip |
Merge 0.7->trunk
Diffstat (limited to 'net/server_select.lua')
-rw-r--r-- | net/server_select.lua | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/net/server_select.lua b/net/server_select.lua index e3a389a8..298e560a 100644 --- a/net/server_select.lua +++ b/net/server_select.lua @@ -343,9 +343,9 @@ wrapconnection = function( server, listeners, socket, ip, serverport, clientport _closelist[ handler ] = nil handler = nil end - if server then - server.remove( ) - end + if server then + server.remove( ) + end out_put "server.lua: closed client handler and removed socket from list" return true end @@ -479,11 +479,11 @@ wrapconnection = function( server, listeners, socket, ip, serverport, clientport bufferqueuelen = 0 bufferlen = 0 _sendlistlen = removesocket( _sendlist, socket, _sendlistlen ) -- delete socket from writelist - _ = needtls and handler:starttls(nil, true) _writetimes[ handler ] = nil if drain then drain(handler) end + _ = needtls and handler:starttls(nil, true) _ = toclose and handler:close( ) return true elseif byte and ( err == "timeout" or err == "wantwrite" ) then -- want write |