# HG changeset patch # User Matthew Wild # Date 1371554086 -3600 # Node ID ea00fc524b957e68305cb5d187f7b2abe83768e4 # Parent a56691e3c7d1252e5397c563f2d2442015d4dbf9 mod_s2s/s2sout.lib: Remove unused variables and imports diff -r a56691e3c7d1 -r ea00fc524b95 plugins/mod_s2s/s2sout.lib.lua --- a/plugins/mod_s2s/s2sout.lib.lua Tue Jun 18 12:12:49 2013 +0100 +++ b/plugins/mod_s2s/s2sout.lib.lua Tue Jun 18 12:14:46 2013 +0100 @@ -18,7 +18,6 @@ local adns = require "net.adns"; local dns = require "net.dns"; local t_insert, t_sort, ipairs = table.insert, table.sort, ipairs; -local st = require "util.stanza"; local local_addresses = require "util.net".local_addresses; local s2s_destroy_session = require "core.s2smanager".destroy_session; @@ -74,7 +73,7 @@ end function s2sout.attempt_connection(host_session, err) - local from_host, to_host = host_session.from_host, host_session.to_host; + local to_host = host_session.to_host; local connect_host, connect_port = to_host and idna_to_ascii(to_host), 5269; if not connect_host then @@ -267,10 +266,7 @@ function s2sout.make_connect(host_session, connect_host, connect_port) (host_session.log or log)("info", "Beginning new connection attempt to %s ([%s]:%d)", host_session.to_host, connect_host.addr, connect_port); - -- Ok, we're going to try to connect - - local from_host, to_host = host_session.from_host, host_session.to_host; - + -- Reset secure flag in case this is another -- connection attempt after a failed STARTTLS host_session.secure = nil;