X-Git-Url: https://git.enpas.org/?a=blobdiff_plain;f=tools%2Fxep227toprosody.lua;h=521851e93f3ac8bcc54850fb9d619e7f4ada345d;hb=670c0bb01015bf63176eafc5c605c800c7053e1f;hp=e95a9d5953a5eed91a7de30d7fd4eea0d489dc97;hpb=e9f9272a0f1f9e112973259bf45db0bbd5bac9c1;p=prosody.git diff --git a/tools/xep227toprosody.lua b/tools/xep227toprosody.lua index e95a9d59..521851e9 100755 --- a/tools/xep227toprosody.lua +++ b/tools/xep227toprosody.lua @@ -202,7 +202,7 @@ function lxp_handlers.StartElement(parser, elementname, attributes) --count = count + 1; if curr_host ~= "" then -- forward to xmlhandlers - user_handlers:StartElement(elementname, attributes); + user_handlers.StartElement(parser, elementname, attributes); elseif (curr_ns == xmlns_xep227) and (name == "host") then curr_host = attributes["jid"]; -- start of host element print("Begin parsing host "..curr_host); @@ -226,7 +226,7 @@ function lxp_handlers.EndElement(parser, elementname) curr_host = "" -- end of host element else -- forward to xmlhandlers - user_handlers:EndElement(elementname); + user_handlers.EndElement(parser, elementname); end elseif (curr_ns ~= xmlns_xep227) or (name ~= "server-data") then io.stderr:write("Unhandled XML element: ", name, "\n"); @@ -237,7 +237,7 @@ end function lxp_handlers.CharacterData(parser, string) if curr_host ~= "" then -- forward to xmlhandlers - user_handlers:CharacterData(string); + user_handlers.CharacterData(parser, string); end end