Software /
code /
prosody
Comparison
plugins/mod_console.lua @ 3025:f1e1b7629807
mod_console: Ensure that a null byte is printed after sending the banner.
author | Waqas Hussain <waqas20@gmail.com> |
---|---|
date | Fri, 07 May 2010 16:13:05 +0500 |
parent | 3009:06f7d8054065 |
child | 3028:e095d2a98936 |
comparison
equal
deleted
inserted
replaced
3024:9c74785c6351 | 3025:f1e1b7629807 |
---|---|
56 function console_listener.onconnect(conn) | 56 function console_listener.onconnect(conn) |
57 -- Handle new connection | 57 -- Handle new connection |
58 local session = console:new_session(conn); | 58 local session = console:new_session(conn); |
59 sessions[conn] = session; | 59 sessions[conn] = session; |
60 printbanner(session); | 60 printbanner(session); |
61 session.send(string.char(0)); | |
61 end | 62 end |
62 | 63 |
63 function console_listener.onincoming(conn, data) | 64 function console_listener.onincoming(conn, data) |
64 local session = sessions[conn]; | 65 local session = sessions[conn]; |
65 | 66 |