| 433 | |
| 434 | |
| 435 | static int db_traceback (lua_State *L) { |
| 436 | int arg; |
| 437 | lua_State *L1 = getthread(L, &arg); |
| 438 | const char *msg = lua_tostring(L, arg + 1); |
| 439 | if (msg == NULL && !lua_isnoneornil(L, arg + 1)) /* non-string 'msg'? */ |
| 440 | lua_pushvalue(L, arg + 1); /* return it untouched */ |
| 441 | else { |
| 442 | int level = (int)luaL_optinteger(L, arg + 2, (L == L1) ? 1 : 0); |
| 443 | luaL_traceback(L, L1, msg, level); |
| 444 | } |
| 445 | return 1; |
| 446 | } |
| 447 | |
| 448 | |
| 449 | static int db_setcstacklimit (lua_State *L) { |
nothing calls this directly
no test coverage detected