diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2010-05-17 17:39:31 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2010-05-17 17:39:31 -0300 |
commit | 3d45a8eb1c28b71bb00bd353d2c1aa0da2162ce9 (patch) | |
tree | 3e78597ab142db034d834e8fe303669748880b32 /lgc.c | |
parent | 3d80aeab5abb96fb720621a4cb93e1e6f3172499 (diff) | |
download | lua-3d45a8eb1c28b71bb00bd353d2c1aa0da2162ce9.tar.gz lua-3d45a8eb1c28b71bb00bd353d2c1aa0da2162ce9.tar.bz2 lua-3d45a8eb1c28b71bb00bd353d2c1aa0da2162ce9.zip |
really stop collection during finalizers
Diffstat (limited to 'lgc.c')
-rw-r--r-- | lgc.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lgc.c,v 2.94 2010/05/10 18:23:45 roberto Exp roberto $ | 2 | ** $Id: lgc.c,v 2.95 2010/05/11 20:49:26 roberto Exp roberto $ |
3 | ** Garbage Collector | 3 | ** Garbage Collector |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -692,7 +692,7 @@ static void GCTM (lua_State *L, int propagateerrors) { | |||
692 | lu_byte oldah = L->allowhook; | 692 | lu_byte oldah = L->allowhook; |
693 | lu_mem oldd = g->GCdebt; | 693 | lu_mem oldd = g->GCdebt; |
694 | L->allowhook = 0; /* stop debug hooks during GC tag method */ | 694 | L->allowhook = 0; /* stop debug hooks during GC tag method */ |
695 | g->GCdebt = -2 * g->totalbytes; /* avoid GC steps */ | 695 | stopgc(g); /* avoid GC steps */ |
696 | setobj2s(L, L->top, tm); /* push finalizer... */ | 696 | setobj2s(L, L->top, tm); /* push finalizer... */ |
697 | setuvalue(L, L->top+1, udata); /* ... and its argument */ | 697 | setuvalue(L, L->top+1, udata); /* ... and its argument */ |
698 | L->top += 2; /* and (next line) call the finalizer */ | 698 | L->top += 2; /* and (next line) call the finalizer */ |