aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mod_s2s
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2015-05-06 19:21:29 +0100
committerMatthew Wild <mwild1@gmail.com>2015-05-06 19:21:29 +0100
commita540d613cd08b8feee096d19b727d1f5b2cab507 (patch)
treeac1899833b30b87ea97439f061e9b892bd188367 /plugins/mod_s2s
parent8b320cb39f3d22c7af46d33ddfc017a726db30d0 (diff)
parent80bafb72003774e5eb63ef9d3d7960385cfb8c6a (diff)
downloadprosody-a540d613cd08b8feee096d19b727d1f5b2cab507.tar.gz
prosody-a540d613cd08b8feee096d19b727d1f5b2cab507.zip
Merge
Diffstat (limited to 'plugins/mod_s2s')
-rw-r--r--plugins/mod_s2s/mod_s2s.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/plugins/mod_s2s/mod_s2s.lua b/plugins/mod_s2s/mod_s2s.lua
index 1ce63a8b..060e04f6 100644
--- a/plugins/mod_s2s/mod_s2s.lua
+++ b/plugins/mod_s2s/mod_s2s.lua
@@ -625,8 +625,9 @@ end
function listener.onreadtimeout(conn)
local session = sessions[conn];
+ local host = session.host or session.to_host;
if session then
- return (hosts[session.host] or prosody).events.fire_event("s2s-read-timeout", { session = session });
+ return (hosts[host] or prosody).events.fire_event("s2s-read-timeout", { session = session });
end
end