** Called when 'getCcalls(L)' larger or equal to LUAI_MAXCCALLS. ** If equal, raises an overflow error. If value is larger than ** LUAI_MAXCCALLS (which means it is handling an overflow) but ** not much larger, does not report an error (to allow overflow ** handling to work). */
| 163 | ** handling to work). |
| 164 | */ |
| 165 | void luaE_checkcstack (lua_State *L) { |
| 166 | if (getCcalls(L) == LUAI_MAXCCALLS) |
| 167 | luaG_runerror(L, "C stack overflow"); |
| 168 | else if (getCcalls(L) >= (LUAI_MAXCCALLS / 10 * 11)) |
| 169 | luaD_throw(L, LUA_ERRERR); /* error while handing stack error */ |
| 170 | } |
| 171 | |
| 172 | |
| 173 | LUAI_FUNC void luaE_incCstack (lua_State *L) { |
no test coverage detected