summaryrefslogtreecommitdiff
path: root/ltests.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2010-03-25 10:06:36 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2010-03-25 10:06:36 -0300
commit3aa95981779aa8144da11f328a25bf79bd141c41 (patch)
tree7397217a9d8e89c7ed9285dc69639442a8a5f019 /ltests.c
parent64d39ed1b6c1cb749a5815002509572020424bf3 (diff)
downloadlua-3aa95981779aa8144da11f328a25bf79bd141c41.tar.gz
lua-3aa95981779aa8144da11f328a25bf79bd141c41.tar.bz2
lua-3aa95981779aa8144da11f328a25bf79bd141c41.zip
'mainthread' is not inserted in the 'allgc' list anymore, but swept
separately.
Diffstat (limited to 'ltests.c')
-rw-r--r--ltests.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/ltests.c b/ltests.c
index 123ff64e..d8c91947 100644
--- a/ltests.c
+++ b/ltests.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: ltests.c,v 2.87 2010/01/13 16:18:25 roberto Exp roberto $ 2** $Id: ltests.c,v 2.88 2010/03/24 13:07:01 roberto Exp roberto $
3** Internal Module for Debugging of the Lua Implementation 3** Internal Module for Debugging of the Lua Implementation
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -375,11 +375,10 @@ int lua_checkmemory (lua_State *L) {
375 checkliveness(g, &g->l_registry); 375 checkliveness(g, &g->l_registry);
376 lua_assert(!isdead(g, obj2gco(g->l_gt))); 376 lua_assert(!isdead(g, obj2gco(g->l_gt)));
377 checkstack(g, g->mainthread); 377 checkstack(g, g->mainthread);
378 for (o = g->allgc; o != obj2gco(g->mainthread); o = gch(o)->next) { 378 for (o = g->allgc; o != NULL; o = gch(o)->next) {
379 lua_assert(!testbits(o->gch.marked, bit2mask(SEPARATED, SFIXEDBIT))); 379 lua_assert(!testbits(o->gch.marked, bitmask(SEPARATED)));
380 checkobject(g, o); 380 checkobject(g, o);
381 } 381 }
382 lua_assert(testbit(o->gch.marked, SFIXEDBIT));
383 for (o = g->udgc; o != NULL; o = gch(o)->next) { 382 for (o = g->udgc; o != NULL; o = gch(o)->next) {
384 lua_assert(gch(o)->tt == LUA_TUSERDATA && 383 lua_assert(gch(o)->tt == LUA_TUSERDATA &&
385 !isdead(g, o) && 384 !isdead(g, o) &&