Software /
code /
prosody
Comparison
core/sessionmanager.lua @ 9069:22e5f11c778a
sessionmanager, mod_s2s: Bring debug line for outgoing stanzas in line with that for incoming
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Tue, 24 Jul 2018 19:07:26 +0200 |
parent | 9066:af97ecd00734 |
child | 9070:21730a3642fe |
comparison
equal
deleted
inserted
replaced
9068:95ee62b5afef | 9069:22e5f11c778a |
---|---|
30 local function new_session(conn) | 30 local function new_session(conn) |
31 local session = { conn = conn, type = "c2s_unauthed", conntime = gettime() }; | 31 local session = { conn = conn, type = "c2s_unauthed", conntime = gettime() }; |
32 local filter = initialize_filters(session); | 32 local filter = initialize_filters(session); |
33 local w = conn.write; | 33 local w = conn.write; |
34 session.send = function (t) | 34 session.send = function (t) |
35 session.log("debug", "sending: %s", t.top_tag and t:top_tag() or t:match("^[^>]*>?")); | 35 session.log("debug", "Sending[%s]: %s", session.type, t.top_tag and t:top_tag() or t:match("^[^>]*>?")); |
36 if t.name then | 36 if t.name then |
37 t = filter("stanzas/out", t); | 37 t = filter("stanzas/out", t); |
38 end | 38 end |
39 if t then | 39 if t then |
40 t = filter("bytes/out", tostring(t)); | 40 t = filter("bytes/out", tostring(t)); |