Software /
code /
prosody
Diff
plugins/mod_s2s/mod_s2s.lua @ 4960:8950510ddb2e
mod_s2s: Make unauthed session timeout a little more aggressive... otherwise it's possible for sessions to slip under the net and never get killed off
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Sun, 22 Jul 2012 16:45:27 +0100 |
parent | 4906:89df1f03546a |
child | 4968:a6d3ac11a7af |
line wrap: on
line diff
--- a/plugins/mod_s2s/mod_s2s.lua Sun Jul 22 16:29:52 2012 +0100 +++ b/plugins/mod_s2s/mod_s2s.lua Sun Jul 22 16:45:27 2012 +0100 @@ -413,11 +413,9 @@ return handlestanza(session, stanza); end - local conn = session.conn; add_task(connect_timeout, function () - if session.conn ~= conn or session.connecting - or session.type == "s2sin" or session.type == "s2sout" then - return; -- Ok, we're connect[ed|ing] + if session.type == "s2sin" or session.type == "s2sout" then + return; -- Ok, we're connected end -- Not connected, need to close session and clean up (session.log or log)("debug", "Destroying incomplete session %s->%s due to inactivity",