aboutsummaryrefslogtreecommitdiffstats
path: root/main.lua
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2008-10-02 01:08:58 +0100
committerMatthew Wild <mwild1@gmail.com>2008-10-02 01:08:58 +0100
commit6db3d039b3d8d55c9e03ebdc776cf1a23dd826c2 (patch)
tree2d39390e5a9289101ba6910992084f09647ccfeb /main.lua
parentf1cc4eb60fc94093602025044af230f10634efe4 (diff)
downloadprosody-6db3d039b3d8d55c9e03ebdc776cf1a23dd826c2.tar.gz
prosody-6db3d039b3d8d55c9e03ebdc776cf1a23dd826c2.zip
SASL!
(but before you get too excited, no resource binding yet. And yes, there are still plenty of rough edges to the code...) ((eg. must move <stream:features> out of xmlhandlers.lua o_O ))
Diffstat (limited to 'main.lua')
-rw-r--r--main.lua8
1 files changed, 4 insertions, 4 deletions
diff --git a/main.lua b/main.lua
index b8a15adf..6712694d 100644
--- a/main.lua
+++ b/main.lua
@@ -21,6 +21,7 @@ require "core.modulemanager"
require "core.usermanager"
require "core.sessionmanager"
require "core.stanza_router"
+require "net.connhandlers"
require "util.stanza"
require "util.jid"
@@ -31,7 +32,6 @@ local t_concatall = function (t, sep) local tt = {}; for _, s in ipairs(t) do t_
local m_random = math.random;
local format = string.format;
local st = stanza;
-local init_xmlhandlers = xmlhandlers.init_xmlhandlers;
------------------------------
@@ -63,8 +63,8 @@ function handler(conn, data, err)
print("Client connected");
session.stanza_dispatch = function (stanza) return core_process_stanza(session, stanza); end
- session.xml_handlers = init_xmlhandlers(session);
- session.parser = lxp.new(session.xml_handlers, ":");
+
+ session.connhandler = connhandlers.new("xmpp-client", session);
function session.disconnect(err)
if session.last_presence and session.last_presence.attr.type ~= "unavailable" then
@@ -82,7 +82,7 @@ function handler(conn, data, err)
end
end
if data then
- session.parser:parse(data);
+ session.connhandler:data(data);
end
--log("info", "core", "Client disconnected, connection closed");