Software /
code /
prosody
Comparison
core/s2smanager.lua @ 4025:cc2e75e49cfb
s2smanager: new_outgoing(): Destroy session if first connection attempt fails immediately (e.g. can't create sockets)
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Fri, 24 Dec 2010 04:56:02 +0000 |
parent | 4021:5af5fdaaa940 |
child | 4026:21edd42768b5 |
comparison
equal
deleted
inserted
replaced
4024:d2f80697c329 | 4025:cc2e75e49cfb |
---|---|
188 | 188 |
189 initialize_filters(host_session); | 189 initialize_filters(host_session); |
190 | 190 |
191 if connect ~= false then | 191 if connect ~= false then |
192 -- Kick the connection attempting machine into life | 192 -- Kick the connection attempting machine into life |
193 attempt_connection(host_session); | 193 if not attempt_connection(host_session) then |
194 -- Intentionally not returning here, the | |
195 -- session is needed, connected or not | |
196 destroy_session(host_session); | |
197 end | |
194 end | 198 end |
195 | 199 |
196 if not host_session.sends2s then | 200 if not host_session.sends2s then |
197 -- A sends2s which buffers data (until the stream is opened) | 201 -- A sends2s which buffers data (until the stream is opened) |
198 -- note that data in this buffer will be sent before the stream is authed | 202 -- note that data in this buffer will be sent before the stream is authed |