Mercurial > prosody-hg
comparison core/s2smanager.lua @ 4021:5af5fdaaa940
s2smanager: Give all new outgoing s2s sessions a close method by default (destroy_session)
| author | Matthew Wild <mwild1@gmail.com> |
|---|---|
| date | Fri, 24 Dec 2010 04:49:30 +0000 |
| parents | 472691075967 |
| children | cc2e75e49cfb |
comparison
equal
deleted
inserted
replaced
| 4020:472691075967 | 4021:5af5fdaaa940 |
|---|---|
| 174 local host_session = { to_host = to_host, from_host = from_host, host = from_host, | 174 local host_session = { to_host = to_host, from_host = from_host, host = from_host, |
| 175 notopen = true, type = "s2sout_unauthed", direction = "outgoing", | 175 notopen = true, type = "s2sout_unauthed", direction = "outgoing", |
| 176 open_stream = session_open_stream }; | 176 open_stream = session_open_stream }; |
| 177 | 177 |
| 178 hosts[from_host].s2sout[to_host] = host_session; | 178 hosts[from_host].s2sout[to_host] = host_session; |
| 179 | |
| 180 host_session.close = destroy_session; -- This gets replaced by xmppserver_listener later | |
| 179 | 181 |
| 180 local log; | 182 local log; |
| 181 do | 183 do |
| 182 local conn_name = "s2sout"..tostring(host_session):match("[a-f0-9]*$"); | 184 local conn_name = "s2sout"..tostring(host_session):match("[a-f0-9]*$"); |
| 183 log = logger_init(conn_name); | 185 log = logger_init(conn_name); |
