aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--plugins/mod_s2s.lua5
1 files changed, 4 insertions, 1 deletions
diff --git a/plugins/mod_s2s.lua b/plugins/mod_s2s.lua
index 0674f981..9fed6e0c 100644
--- a/plugins/mod_s2s.lua
+++ b/plugins/mod_s2s.lua
@@ -177,7 +177,10 @@ function route_to_new_session(event)
end
local function keepalive(event)
- return event.session.sends2s(' ');
+ local session = event.session;
+ if not session.notopen then
+ return event.session.send(' ');
+ end
end
module:hook("s2s-read-timeout", keepalive, -1);