Revert "Add backtrace to error function"

This reverts commit 5b518ed2feff28c9bf21ad940c1b211b72d71bd1.

This caused duplicate tracebacks and tracebacks when unwanted.
It also ignored the level argument to error() and didn't pass the message (or level) to debug.traceback().
Use xpcall() or lua_pcall()'s errorhandler argument instead.
This commit is contained in:
ShadowNinja 2014-04-23 22:37:27 -04:00 committed by Nils Dagsson Moskopp
parent 90e3c67beb
commit 87e7000acc
Signed by: erle
GPG Key ID: A3BC671C35191080
2 changed files with 0 additions and 12 deletions

View File

@ -10,12 +10,6 @@ print = minetest.debug
math.randomseed(os.time())
os.setlocale("C", "numeric")
local errorfct = error
error = function(text)
print(debug.traceback(""))
errorfct(text)
end
-- Load other files
local modpath = minetest.get_modpath("__builtin")
dofile(modpath.."/serialize.lua")

View File

@ -2,12 +2,6 @@ print = engine.debug
math.randomseed(os.time())
os.setlocale("C", "numeric")
local errorfct = error
error = function(text)
print(debug.traceback(""))
errorfct(text)
end
local scriptpath = engine.get_scriptdir()
mt_color_grey = "#AAAAAA"