diff options
Diffstat (limited to 'src/lib_base.c')
-rw-r--r-- | src/lib_base.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib_base.c b/src/lib_base.c index 887fea7a..ca268b1d 100644 --- a/src/lib_base.c +++ b/src/lib_base.c | |||
@@ -435,13 +435,13 @@ LJLIB_CF(gcinfo) | |||
435 | LJLIB_CF(collectgarbage) | 435 | LJLIB_CF(collectgarbage) |
436 | { | 436 | { |
437 | int opt = lj_lib_checkopt(L, 1, LUA_GCCOLLECT, /* ORDER LUA_GC* */ | 437 | int opt = lj_lib_checkopt(L, 1, LUA_GCCOLLECT, /* ORDER LUA_GC* */ |
438 | "\4stop\7restart\7collect\5count\1\377\4step\10setpause\12setstepmul"); | 438 | "\4stop\7restart\7collect\5count\1\377\4step\10setpause\12setstepmul\1\377\11isrunning"); |
439 | int32_t data = lj_lib_optint(L, 2, 0); | 439 | int32_t data = lj_lib_optint(L, 2, 0); |
440 | if (opt == LUA_GCCOUNT) { | 440 | if (opt == LUA_GCCOUNT) { |
441 | setnumV(L->top, (lua_Number)G(L)->gc.total/1024.0); | 441 | setnumV(L->top, (lua_Number)G(L)->gc.total/1024.0); |
442 | } else { | 442 | } else { |
443 | int res = lua_gc(L, opt, data); | 443 | int res = lua_gc(L, opt, data); |
444 | if (opt == LUA_GCSTEP) | 444 | if (opt == LUA_GCSTEP || opt == LUA_GCISRUNNING) |
445 | setboolV(L->top, res); | 445 | setboolV(L->top, res); |
446 | else | 446 | else |
447 | setintV(L->top, res); | 447 | setintV(L->top, res); |