Software /
code /
prosody
Changeset
2885:ae72c0dd6f1f
mod_compression: More robust stanza processing.
author | Waqas Hussain <waqas20@gmail.com> |
---|---|
date | Tue, 09 Mar 2010 18:19:50 +0500 |
parents | 2884:6807f5fa0eb4 |
children | 2886:3baee526d714 |
files | plugins/mod_compression.lua |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/plugins/mod_compression.lua Tue Mar 09 18:11:45 2010 +0500 +++ b/plugins/mod_compression.lua Tue Mar 09 18:19:50 2010 +0500 @@ -47,7 +47,8 @@ end -- checking if the compression method is supported - local method = stanza:child_with_name("method")[1]; + local method = stanza:child_with_name("method"); + method = method and method[1]; if method == "zlib" then -- create deflate and inflate streams local status, deflate_stream = pcall(zlib.deflate, compression_level);