diff options
-rw-r--r-- | lstate.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lstate.c,v 2.79 2010/04/12 16:07:06 roberto Exp roberto $ | 2 | ** $Id: lstate.c,v 2.80 2010/04/14 15:14:21 roberto Exp roberto $ |
3 | ** Global State | 3 | ** Global State |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -218,7 +218,7 @@ LUA_API lua_State *lua_newstate (lua_Alloc f, void *ud) { | |||
218 | int i; | 218 | int i; |
219 | lua_State *L; | 219 | lua_State *L; |
220 | global_State *g; | 220 | global_State *g; |
221 | LG *l = cast(LG *, (*f)(ud, NULL, 0, sizeof(LG))); | 221 | LG *l = cast(LG *, (*f)(ud, NULL, LUA_TTHREAD, sizeof(LG))); |
222 | if (l == NULL) return NULL; | 222 | if (l == NULL) return NULL; |
223 | L = &l->l.l; | 223 | L = &l->l.l; |
224 | g = &l->g; | 224 | g = &l->g; |