Software /
code /
prosody
Comparison
core/s2smanager.lua @ 2676:4516888fc42d
s2smanager: Use s2smanager log() if session doesn't have a logger (thanks Flo)
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Fri, 19 Feb 2010 03:30:27 +0000 |
parent | 2622:5ced53147f86 |
child | 2714:9c5d8e0c146e |
comparison
equal
deleted
inserted
replaced
2675:ab643a77da2d | 2676:4516888fc42d |
---|---|
299 | 299 |
300 return true; | 300 return true; |
301 end | 301 end |
302 | 302 |
303 function make_connect(host_session, connect_host, connect_port) | 303 function make_connect(host_session, connect_host, connect_port) |
304 host_session.log("info", "Beginning new connection attempt to %s (%s:%d)", host_session.to_host, connect_host, connect_port); | 304 (host_session.log or log)("info", "Beginning new connection attempt to %s (%s:%d)", host_session.to_host, connect_host, connect_port); |
305 -- Ok, we're going to try to connect | 305 -- Ok, we're going to try to connect |
306 | 306 |
307 local from_host, to_host = host_session.from_host, host_session.to_host; | 307 local from_host, to_host = host_session.from_host, host_session.to_host; |
308 | 308 |
309 local conn, handler = socket.tcp() | 309 local conn, handler = socket.tcp() |