Mercurial > prosody-hg
comparison plugins/mod_s2s/s2sout.lib.lua @ 5388:f833d2188c16
mod_s2s: Reset secure flag on new connection attempt
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Mon, 25 Mar 2013 19:08:15 +0100 |
| parents | 43059357b2f0 |
| children | 40e7a6cf15ff |
comparison
equal
deleted
inserted
replaced
| 5387:1130887e0d41 | 5388:f833d2188c16 |
|---|---|
| 269 (host_session.log or log)("info", "Beginning new connection attempt to %s ([%s]:%d)", host_session.to_host, connect_host.addr, connect_port); | 269 (host_session.log or log)("info", "Beginning new connection attempt to %s ([%s]:%d)", host_session.to_host, connect_host.addr, connect_port); |
| 270 -- Ok, we're going to try to connect | 270 -- Ok, we're going to try to connect |
| 271 | 271 |
| 272 local from_host, to_host = host_session.from_host, host_session.to_host; | 272 local from_host, to_host = host_session.from_host, host_session.to_host; |
| 273 | 273 |
| 274 -- Reset secure flag in case this is another | |
| 275 -- connection attempt after a failed STARTTLS | |
| 276 host_session.secure = nil; | |
| 277 | |
| 274 local conn, handler; | 278 local conn, handler; |
| 275 if connect_host.proto == "IPv4" then | 279 if connect_host.proto == "IPv4" then |
| 276 conn, handler = socket.tcp(); | 280 conn, handler = socket.tcp(); |
| 277 else | 281 else |
| 278 conn, handler = socket.tcp6(); | 282 conn, handler = socket.tcp6(); |
