Software /
code /
prosody
Diff
plugins/mod_c2s.lua @ 6382:57d23c26039b
Merge 0.9->0.10
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Tue, 02 Sep 2014 22:33:11 +0200 |
parent | 6367:769a3577dd85 |
parent | 6380:4220ffb87b22 |
child | 6630:6735e2d735d6 |
line wrap: on
line diff
--- a/plugins/mod_c2s.lua Tue Sep 02 17:58:12 2014 +0100 +++ b/plugins/mod_c2s.lua Tue Sep 02 22:33:11 2014 +0200 @@ -240,9 +240,9 @@ function session.data(data) -- Parse the data, which will store stanzas in session.pending_stanzas if data then - data = filter("bytes/in", data); - if data then - local ok, err = stream:feed(data); + data = filter("bytes/in", data); + if data then + local ok, err = stream:feed(data); if not ok then log("debug", "Received invalid XML (%s) %d bytes: %s", tostring(err), #data, data:sub(1, 300):gsub("[\r\n]+", " "):gsub("[%z\1-\31]", "_")); session:close("not-well-formed");