Software /
code /
prosody
Comparison
plugins/mod_s2s/s2sout.lib.lua @ 8910:28ec1e024379
mod_s2s: Log a message before trying the next SRV record
This was the only spot where it did `ip_hosts = nil` without logging
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Thu, 14 Jun 2018 16:13:56 +0200 |
parent | 8902:ac21f13798ae |
child | 8911:cea6165a03d0 |
comparison
equal
deleted
inserted
replaced
8909:dbb5ec6885fe | 8910:28ec1e024379 |
---|---|
250 end | 250 end |
251 return true; | 251 return true; |
252 elseif host_session.ip_hosts and #host_session.ip_hosts > host_session.ip_choice then -- Not our first attempt, and we also have IPs left to try | 252 elseif host_session.ip_hosts and #host_session.ip_hosts > host_session.ip_choice then -- Not our first attempt, and we also have IPs left to try |
253 s2sout.try_next_ip(host_session); | 253 s2sout.try_next_ip(host_session); |
254 else | 254 else |
255 log("debug", "Out of IP addresses, trying next SRV record (if any)"); | |
255 host_session.ip_hosts = nil; | 256 host_session.ip_hosts = nil; |
256 if not s2sout.attempt_connection(host_session, "out of IP addresses") then -- Retry if we can | 257 if not s2sout.attempt_connection(host_session, "out of IP addresses") then -- Retry if we can |
257 log("debug", "No other records to try for %s - destroying", host_session.to_host); | 258 log("debug", "No other records to try for %s - destroying", host_session.to_host); |
258 err = err and (": "..err) or ""; | 259 err = err and (": "..err) or ""; |
259 s2s_destroy_session(host_session, "Connecting failed"..err); -- End of the line, we can't | 260 s2s_destroy_session(host_session, "Connecting failed"..err); -- End of the line, we can't |