diff options
author | Matthew Wild <mwild1@gmail.com> | 2009-04-18 04:06:41 +0100 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2009-04-18 04:06:41 +0100 |
commit | 05fbcb767cf2131b62d0dd9a7f0e536e72427d0d (patch) | |
tree | 650f35a0f216db097aded9a337654c0211258dec | |
parent | f28ce3ccacbf3be4c51b22798eabb2770e3a7e81 (diff) | |
download | prosody-05fbcb767cf2131b62d0dd9a7f0e536e72427d0d.tar.gz prosody-05fbcb767cf2131b62d0dd9a7f0e536e72427d0d.zip |
core.xmlhandlers: expat is the XML parser, not us. Don't reject valid XML.
-rw-r--r-- | core/xmlhandlers.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/xmlhandlers.lua b/core/xmlhandlers.lua index 1409a1ec..67a0829d 100644 --- a/core/xmlhandlers.lua +++ b/core/xmlhandlers.lua @@ -57,7 +57,7 @@ function init_xmlhandlers(session, stream_callbacks) stanza:text(t_concat(chardata)); chardata = {}; end - local curr_ns,name = tagname:match("^(.+)|([%w%-]+)$"); + local curr_ns,name = tagname:match("^(.+)|([^%|]+)$"); if curr_ns ~= stream_default_ns then attr.xmlns = curr_ns; end @@ -109,7 +109,7 @@ function init_xmlhandlers(session, stream_callbacks) end end function xml_handlers:EndElement(tagname) - curr_ns,name = tagname:match("^(.+)|([%w%-]+)$"); + curr_ns,name = tagname:match("^(.+)|([^%|]+)$"); if (not stanza) or (#stanza.last_add > 0 and name ~= stanza.last_add[#stanza.last_add].name) then if tagname == stream_tag then if cb_streamclosed then |