mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-05-24 06:12:27 +00:00
Include variables in redbean lua traceback
This commit is contained in:
parent
be7c5e1071
commit
933f33bcc1
4 changed files with 59 additions and 13 deletions
2
third_party/lua/luacallwithtrace.c
vendored
2
third_party/lua/luacallwithtrace.c
vendored
|
@ -50,7 +50,7 @@ int LuaCallWithTrace(lua_State *L, int nargs, int nres, lua_State *C) {
|
|||
// move the error message
|
||||
lua_xmove(C, L, 1);
|
||||
// replace the error with the traceback on failure
|
||||
luaL_traceback(L, C, lua_tostring(L, -1), 0);
|
||||
luaL_traceback2(L, C, lua_tostring(L, -1), 0);
|
||||
lua_remove(L, -2); // remove the error message
|
||||
} else {
|
||||
if (!lua_checkstack(L, MAX(nresults, nres))) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue