>After learning that the lua_closethread() is not implemented as per the >documentation, I checked out the source code and found: > >void luaE_freethread(lua_State*,lua_State*); This an internal function. It should not be called by clients. About lua_closethread, see http://lua-users.org/lists/lua-l/2003-04/msg00325.html http://lua-users.org/lists/lua-l/2003-07/msg00159.html --lhf