diff options
Diffstat (limited to 'lbaselib.c')
-rw-r--r-- | lbaselib.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lbaselib.c,v 1.164 2005/01/07 19:53:32 roberto Exp roberto $ | 2 | ** $Id: lbaselib.c,v 1.165 2005/01/14 14:19:42 roberto Exp roberto $ |
3 | ** Basic library | 3 | ** Basic library |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -186,9 +186,9 @@ static int luaB_collectgarbage (lua_State *L) { | |||
186 | static const int optsnum[] = {LUA_GCSTOP, LUA_GCRESTART, LUA_GCCOLLECT, | 186 | static const int optsnum[] = {LUA_GCSTOP, LUA_GCRESTART, LUA_GCCOLLECT, |
187 | LUA_GCCOUNT, LUA_GCSTEP, LUA_GCSETPACE, LUA_GCSETSTEPMUL}; | 187 | LUA_GCCOUNT, LUA_GCSTEP, LUA_GCSETPACE, LUA_GCSETSTEPMUL}; |
188 | int o = luaL_findstring(luaL_optstring(L, 1, "collect"), opts); | 188 | int o = luaL_findstring(luaL_optstring(L, 1, "collect"), opts); |
189 | lua_Number ex = luaL_optnumber(L, 2, 0); | 189 | int ex = luaL_optinteger(L, 2, 0); |
190 | luaL_argcheck(L, o >= 0, 1, "invalid option"); | 190 | luaL_argcheck(L, o >= 0, 1, "invalid option"); |
191 | lua_pushinteger(L, lua_gc(L, optsnum[o], ex * 100)); | 191 | lua_pushinteger(L, lua_gc(L, optsnum[o], ex)); |
192 | return 1; | 192 | return 1; |
193 | } | 193 | } |
194 | 194 | ||