Comparison

core/s2smanager.lua @ 7950:f91e7ec9654e

Merge 0.10->trunk
author Kim Alvefur <zash@zash.se>
date Mon, 06 Mar 2017 01:14:32 +0100
parent 7452:d916703d5e18
parent 7947:24170d74b00b
child 8555:4f0f5b49bb03
comparison
equal deleted inserted replaced
7946:c92102fe409b 7950:f91e7ec9654e
69 return setmetatable(session, resting_session); 69 return setmetatable(session, resting_session);
70 end 70 end
71 71
72 local function destroy_session(session, reason) 72 local function destroy_session(session, reason)
73 if session.destroyed then return; end 73 if session.destroyed then return; end
74 (session.log or log)("debug", "Destroying "..tostring(session.direction).." session "..tostring(session.from_host).."->"..tostring(session.to_host)..(reason and (": "..reason) or "")); 74 (session.log or log)("debug", "Destroying "..tostring(session.direction)
75 .." session "..tostring(session.from_host).."->"..tostring(session.to_host)
76 ..(reason and (": "..reason) or ""));
75 77
76 if session.direction == "outgoing" then 78 if session.direction == "outgoing" then
77 hosts[session.from_host].s2sout[session.to_host] = nil; 79 hosts[session.from_host].s2sout[session.to_host] = nil;
78 session:bounce_sendq(reason); 80 session:bounce_sendq(reason);
79 elseif session.direction == "incoming" then 81 elseif session.direction == "incoming" then