Software /
code /
prosody
Comparison
core/s2smanager.lua @ 435:4087aa611de2
Log reason for connection failure
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Wed, 26 Nov 2008 23:47:23 +0000 |
parent | 434:0d7ba3742f7a |
child | 448:2623519b25b0 |
comparison
equal
deleted
inserted
replaced
434:0d7ba3742f7a | 435:4087aa611de2 |
---|---|
126 end | 126 end |
127 elseif host_session.srv_hosts and #host_session.srv_hosts > host_session.srv_choice then -- Not our first attempt, and we also have SRV | 127 elseif host_session.srv_hosts and #host_session.srv_hosts > host_session.srv_choice then -- Not our first attempt, and we also have SRV |
128 host_session.srv_choice = host_session.srv_choice + 1; | 128 host_session.srv_choice = host_session.srv_choice + 1; |
129 local srv_choice = host_session.srv_hosts[host_session.srv_choice]; | 129 local srv_choice = host_session.srv_hosts[host_session.srv_choice]; |
130 connect_host, connect_port = srv_choice.target or to_host, srv_choice.port or connect_port; | 130 connect_host, connect_port = srv_choice.target or to_host, srv_choice.port or connect_port; |
131 host_session.log("debug", "Attempt #%d: This time to %s:%d", host_session.srv_choice, connect_host, connect_port); | 131 host_session.log("debug", "Connection failed (%s). Attempt #%d: This time to %s:%d", tostring(err), host_session.srv_choice, connect_host, connect_port); |
132 else | 132 else |
133 host_session.log("debug", "Out of connection options, can't connect to %s", tostring(host_session.to_host)); | 133 host_session.log("debug", "Out of connection options, can't connect to %s", tostring(host_session.to_host)); |
134 -- We're out of options | 134 -- We're out of options |
135 return false; | 135 return false; |
136 end | 136 end |