diff options
author | Kim Alvefur <zash@zash.se> | 2017-03-06 01:14:32 +0100 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2017-03-06 01:14:32 +0100 |
commit | 0e71fac1d18b0de0e9203cb6b71c971d55c8c70c (patch) | |
tree | e58db2bf464bf09301a9c02c27330c2dba6b926d /core/sessionmanager.lua | |
parent | 2ca03f1a40ea0854e0dda798b82e31c558eed578 (diff) | |
parent | 91d2b2518f3e3d047dc43f59db3f7025d29ab86c (diff) | |
download | prosody-0e71fac1d18b0de0e9203cb6b71c971d55c8c70c.tar.gz prosody-0e71fac1d18b0de0e9203cb6b71c971d55c8c70c.zip |
Merge 0.10->trunk
Diffstat (limited to 'core/sessionmanager.lua')
-rw-r--r-- | core/sessionmanager.lua | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/core/sessionmanager.lua b/core/sessionmanager.lua index 3224a84d..9ec05539 100644 --- a/core/sessionmanager.lua +++ b/core/sessionmanager.lua @@ -5,6 +5,7 @@ -- This project is MIT/X11 licensed. Please see the -- COPYING file in the source package for more information. -- +-- luacheck: globals prosody.full_sessions prosody.bare_sessions local tostring, setmetatable = tostring, setmetatable; local pairs, next= pairs, next; @@ -77,7 +78,10 @@ local function retire_session(session) end local function destroy_session(session, err) - (session.log or log)("debug", "Destroying session for %s (%s@%s)%s", session.full_jid or "(unknown)", session.username or "(unknown)", session.host or "(unknown)", err and (": "..err) or ""); + (session.log or log)("debug", "Destroying session for %s (%s@%s)%s", + session.full_jid or "(unknown)", session.username or "(unknown)", + session.host or "(unknown)", err and (": "..err) or ""); + if session.destroyed then return; end -- Remove session/resource from user's session list |