diff options
author | Lua Team <team@lua.org> | 2011-12-05 12:00:00 +0000 |
---|---|---|
committer | repogen <> | 2011-12-05 12:00:00 +0000 |
commit | 3a66913821e41b57d0f5e5f464d0b7b35b4cc131 (patch) | |
tree | b35640d90c10aefe47e7822eb5de583d6fb94a64 /src/lmem.h | |
parent | ed0f7cc8d3f96dce4dac98bc395506f0513a332c (diff) | |
download | lua-github-5.2.0-rc5.tar.gz |
Lua 5.2.0-rc55.2.0-rc5
Diffstat (limited to 'src/lmem.h')
-rw-r--r-- | src/lmem.h | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -1,5 +1,5 @@ /* -** $Id: lmem.h,v 1.37 2011/11/30 12:42:49 roberto Exp $ +** $Id: lmem.h,v 1.38 2011/12/02 13:26:54 roberto Exp $ ** Interface to Memory Manager ** See Copyright Notice in lua.h */ @@ -15,9 +15,9 @@ #define luaM_reallocv(L,b,on,n,e) \ - ((cast(size_t, (n)+1) <= MAX_SIZET/(e)) ? /* +1 to avoid warnings */ \ - luaM_realloc_(L, (b), (on)*(e), (n)*(e)) : \ - (luaM_toobig(L), NULL)) + ((cast(size_t, (n)+1) > MAX_SIZET/(e)) ? /* +1 to avoid warnings */ \ + (luaM_toobig(L), (void *)0) : \ + luaM_realloc_(L, (b), (on)*(e), (n)*(e))) #define luaM_freemem(L, b, s) luaM_realloc_(L, (b), (s), 0) #define luaM_free(L, b) luaM_realloc_(L, (b), sizeof(*(b)), 0) |