MCPcopy Create free account
hub / github.com/BZFlag-Dev/bzflag / gctm

Function gctm

other_src/lua/src/loadlib.cpp:301–306  ·  view source on GitHub ↗

** __gc tag method: calls library's `ll_unloadlib' function with the lib ** handle */

Source from the content-addressed store, hash-verified

299** handle
300*/
301static int gctm (lua_State *L) {
302 void **lib = (void **)luaL_checkudata(L, 1, "_LOADLIB");
303 if (*lib) ll_unloadlib(*lib);
304 *lib = NULL; /* mark library as closed */
305 return 0;
306}
307
308
309static int ll_loadfunc (lua_State *L, const char *path, const char *sym) {

Callers

nothing calls this directly

Calls 2

luaL_checkudataFunction · 0.70
ll_unloadlibFunction · 0.70

Tested by

no test coverage detected