MCPcopy Create free account
hub / github.com/BigPig0/RelayLive / preinit_thread

Function preinit_thread

ThirdParty/lua/lua/lstate.c:219–236  ·  view source on GitHub ↗

** preinitialize a thread with consistent values without allocating ** any memory (to avoid errors) */

Source from the content-addressed store, hash-verified

217** any memory (to avoid errors)
218*/
219static void preinit_thread (lua_State *L, global_State *g) {
220 G(L) = g;
221 L->stack = NULL;
222 L->ci = NULL;
223 L->stacksize = 0;
224 L->twups = L; /* thread has no upvalues */
225 L->errorJmp = NULL;
226 L->nCcalls = 0;
227 L->hook = NULL;
228 L->hookmask = 0;
229 L->basehookcount = 0;
230 L->allowhook = 1;
231 resethookcount(L);
232 L->openupval = NULL;
233 L->nny = 1;
234 L->status = LUA_OK;
235 L->errfunc = 0;
236}
237
238
239static void close_state (lua_State *L) {

Callers 2

lua_newthreadFunction · 0.85
lua_newstateFunction · 0.85

Calls 1

GFunction · 0.50

Tested by

no test coverage detected