aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--core/s2smanager.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/core/s2smanager.lua b/core/s2smanager.lua
index c6e6df8e..4e6dba5b 100644
--- a/core/s2smanager.lua
+++ b/core/s2smanager.lua
@@ -105,6 +105,7 @@ function send_to_host(from_host, to_host, data)
log("error", "Trying to send a stanza to ourselves??")
log("error", "Traceback: %s", get_traceback());
log("error", "Stanza: %s", tostring(data));
+ return false;
else
(host.log or log)("debug", "going to send stanza to "..to_host.." from "..from_host);
-- FIXME
@@ -125,8 +126,10 @@ function send_to_host(from_host, to_host, data)
if (not host_session.connecting) and (not host_session.conn) then
log("warn", "Connection to %s failed already, destroying session...", to_host);
destroy_session(host_session);
+ return false;
end
end
+ return true;
end
local open_sessions = 0;