diff options
author | Matthew Wild <mwild1@gmail.com> | 2008-11-09 20:15:31 +0000 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2008-11-09 20:15:31 +0000 |
commit | bc83d650a03de76cad050fda72b1108924cb282b (patch) | |
tree | 6bb2809a1317f5c8c8bed2d05ba5566496ee6f09 | |
parent | a94c596c02852294020e5d1b86a70e04ec4b9e5d (diff) | |
download | prosody-bc83d650a03de76cad050fda72b1108924cb282b.tar.gz prosody-bc83d650a03de76cad050fda72b1108924cb282b.zip |
Actually show error and position when we show a traceback :)
-rw-r--r-- | net/xmppclient_listener.lua | 2 | ||||
-rw-r--r-- | net/xmppserver_listener.lua | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/net/xmppclient_listener.lua b/net/xmppclient_listener.lua index 64747bc5..ca4cbbb0 100644 --- a/net/xmppclient_listener.lua +++ b/net/xmppclient_listener.lua @@ -62,7 +62,7 @@ function xmppclient.listener(conn, data) -- (I'm on a mission, no time to fix now) -- Debug version -- - local function handleerr() print("Traceback:", debug.traceback()); end + local function handleerr(err) print("Traceback:", err, debug.traceback()); end session.stanza_dispatch = function (stanza) return select(2, xpcall(function () return core_process_stanza(session, stanza); end, handleerr)); end -- session.stanza_dispatch = function (stanza) return core_process_stanza(session, stanza); end diff --git a/net/xmppserver_listener.lua b/net/xmppserver_listener.lua index f8b5d1c8..ee3faa8f 100644 --- a/net/xmppserver_listener.lua +++ b/net/xmppserver_listener.lua @@ -64,7 +64,7 @@ function xmppserver.listener(conn, data) -- (I'm on a mission, no time to fix now) -- Debug version -- - local function handleerr() print("Traceback:", debug.traceback()); end + local function handleerr(err) print("Traceback:", err, debug.traceback()); end session.stanza_dispatch = function (stanza) return select(2, xpcall(function () return core_process_stanza(session, stanza); end, handleerr)); end -- session.stanza_dispatch = function (stanza) return core_process_stanza(session, stanza); end |