From 565e6d74e1440b1500d0ba0d3757307de0a38b9e Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Thu, 19 Sep 2002 10:03:53 -0300 Subject: state's buffer is used only for chars --- lobject.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lobject.c') diff --git a/lobject.c b/lobject.c index 5845e695..dd8bfe08 100644 --- a/lobject.c +++ b/lobject.c @@ -1,5 +1,5 @@ /* -** $Id: lobject.c,v 1.86 2002/08/07 14:35:55 roberto Exp roberto $ +** $Id: lobject.c,v 1.87 2002/09/02 19:54:49 roberto Exp roberto $ ** Some generic functions over Lua objects ** See Copyright Notice in lua.h */ @@ -72,9 +72,9 @@ int luaO_rawequalObj (const TObject *t1, const TObject *t2) { } -void *luaO_openspaceaux (lua_State *L, size_t n) { +char *luaO_openspace (lua_State *L, size_t n) { if (n > G(L)->Mbuffsize) { - G(L)->Mbuffer = luaM_realloc(L, G(L)->Mbuffer, G(L)->Mbuffsize, n); + luaM_reallocvector(L, G(L)->Mbuffer, G(L)->Mbuffsize, n, char); G(L)->Mbuffsize = n; } return G(L)->Mbuffer; -- cgit v1.2.3-55-g6feb