From 12c59fd50ce83f4c16184c9802d40626843cc48e Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Mon, 6 Apr 2009 23:43:48 +0100 Subject: core.s2smanager: Check for valid host and port before attempting connection --- core/s2smanager.lua | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'core/s2smanager.lua') diff --git a/core/s2smanager.lua b/core/s2smanager.lua index 4c758159..158536d8 100644 --- a/core/s2smanager.lua +++ b/core/s2smanager.lua @@ -177,6 +177,11 @@ function attempt_connection(host_session, err) return false; end + if not (connect_host and connect_port) then + -- Likely we couldn't resolve DNS + return false; + end + -- Ok, we're going to try to connect conn:settimeout(0); local success, err = conn:connect(connect_host, connect_port); -- cgit v1.2.3 From 493839e2acc5b05bec6733c5a345ffff6ddd46d1 Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Wed, 8 Apr 2009 20:01:53 +0100 Subject: core.s2smanager: Look away... wait for it... now! Hopefully s2s should be back to normal. --- core/s2smanager.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'core/s2smanager.lua') diff --git a/core/s2smanager.lua b/core/s2smanager.lua index 158536d8..0ef8e241 100644 --- a/core/s2smanager.lua +++ b/core/s2smanager.lua @@ -250,7 +250,7 @@ function streamopened(session, attr) end function streamclosed(session) - session.send(""); + session.sends2s(""); session.notopen = true; end -- cgit v1.2.3