diff options
author | Kim Alvefur <zash@zash.se> | 2013-05-10 22:29:03 +0200 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2013-05-10 22:29:03 +0200 |
commit | 1dcdcf546304810a950d5e3c9fb1cfbee2915ed8 (patch) | |
tree | f7786b25fd7e50c5019e193f49d194508100e019 /plugins | |
parent | fc293d102131bc1b7ca985c76f04ae4ace114401 (diff) | |
download | prosody-1dcdcf546304810a950d5e3c9fb1cfbee2915ed8.tar.gz prosody-1dcdcf546304810a950d5e3c9fb1cfbee2915ed8.zip |
mod_c2s: Fix session:close() when a stanza is passed as reason
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/mod_c2s.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/mod_c2s.lua b/plugins/mod_c2s.lua index efef8763..1d2dd6dd 100644 --- a/plugins/mod_c2s.lua +++ b/plugins/mod_c2s.lua @@ -157,7 +157,7 @@ local function session_close(session, reason) session.send("</stream:stream>"); function session.send() return false; end - local reason = (reason and (reason.text or reason.condition)) or reason; + local reason = (reason and (reason.name or reason.text or reason.condition)) or reason; session.log("info", "c2s stream for %s closed: %s", session.full_jid or ("<"..session.ip..">"), reason or "session closed"); -- Authenticated incoming stream may still be sending us stanzas, so wait for </stream:stream> from remote |