Software /
code /
prosody-modules
Diff
mod_log_json/mod_log_json.lua @ 3748:27abf3b6819a
mod_log_json: Use correct method to specify remote endpoint
Fun fact, on TCP connections :connect and :setpeername is the same function
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Wed, 13 Nov 2019 17:57:54 +0100 |
parent | 3747:f288177f4c5d |
child | 3758:900ea02ab00b |
line wrap: on
line diff
--- a/mod_log_json/mod_log_json.lua Wed Nov 13 17:54:54 2019 +0100 +++ b/mod_log_json/mod_log_json.lua Wed Nov 13 17:57:54 2019 +0100 @@ -16,7 +16,7 @@ end elseif config.udp_host and config.udp_port then local conn = socket.udp(); - conn:connect(config.udp_host, config.udp_port); + conn:setpeername(config.udp_host, config.udp_port); function send(payload) conn:send(payload); end