aboutsummaryrefslogtreecommitdiff
path: root/lmem.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2018-06-18 09:08:10 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2018-06-18 09:08:10 -0300
commitaf70905246acfad225904b64d027e5b01c7b10eb (patch)
treeb6d62db411706f5317e1269aff90e05399cd51b8 /lmem.c
parentb95e46621873cfb460e1d11dcd153914d5d69f86 (diff)
downloadlua-af70905246acfad225904b64d027e5b01c7b10eb.tar.gz
lua-af70905246acfad225904b64d027e5b01c7b10eb.tar.bz2
lua-af70905246acfad225904b64d027e5b01c7b10eb.zip
no need to check whether libraries and host use the same kernel;
Lua should work correctly with several copies of the kernel
Diffstat (limited to 'lmem.c')
-rw-r--r--lmem.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lmem.c b/lmem.c
index 5c73acd5..56b4affe 100644
--- a/lmem.c
+++ b/lmem.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lmem.c,v 1.96 2018/01/28 15:13:26 roberto Exp roberto $ 2** $Id: lmem.c,v 1.97 2018/05/30 14:25:52 roberto Exp roberto $
3** Interface to Memory Manager 3** Interface to Memory Manager
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -123,7 +123,7 @@ void luaM_free_ (lua_State *L, void *block, size_t osize) {
123static void *tryagain (lua_State *L, void *block, 123static void *tryagain (lua_State *L, void *block,
124 size_t osize, size_t nsize) { 124 size_t osize, size_t nsize) {
125 global_State *g = G(L); 125 global_State *g = G(L);
126 if (g->version) { /* is state fully build? */ 126 if (ttisnil(&g->nilvalue)) { /* is state fully build? */
127 luaC_fullgc(L, 1); /* try to free some memory... */ 127 luaC_fullgc(L, 1); /* try to free some memory... */
128 return (*g->frealloc)(g->ud, block, osize, nsize); /* try again */ 128 return (*g->frealloc)(g->ud, block, osize, nsize); /* try again */
129 } 129 }