diff mod_s2s_keepalive/mod_s2s_keepalive.lua @ 4293:edde5905744a

mod_s2s_keepalive: Don't send whitespace keepalives before s2sin stream is open Could possibly result in whitespace before the XML and stream header, which isn't allowed by the parser. Don't think s2sout is affected, as the stream is opened early and doesn't have to wait for the other end. Thanks Ge0rG
author Kim Alvefur <zash@zash.se>
date Thu, 10 Dec 2020 11:57:03 +0100
parents 93a980ac1816
children 15c4eabdcea0
line wrap: on
line diff
--- a/mod_s2s_keepalive/mod_s2s_keepalive.lua	Wed Dec 09 22:32:31 2020 +0000
+++ b/mod_s2s_keepalive/mod_s2s_keepalive.lua	Thu Dec 10 11:57:03 2020 +0100
@@ -23,6 +23,7 @@
 
 	for session in pairs(prosody.incoming_s2s) do
 		if session.type ~= "s2sin_unauthed"
+		and not session.notopen
 		and session.to_host == host
 		and (not(keepalive_servers) or keepalive_servers:contains(session.from_host)) then
 			if not s2sout[session.from_host] then ping_hosts[session.from_host] = true; end