aboutsummaryrefslogtreecommitdiff
path: root/lgc.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>1998-01-19 17:49:22 -0200
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>1998-01-19 17:49:22 -0200
commitd49e4dd752928c5869a75c444b503060b2634968 (patch)
tree4e13ace68c6940dd12efae1014b18237e1004caa /lgc.c
parent981fddea022b6cad7768223353b4e7386080c271 (diff)
downloadlua-d49e4dd752928c5869a75c444b503060b2634968.tar.gz
lua-d49e4dd752928c5869a75c444b503060b2634968.tar.bz2
lua-d49e4dd752928c5869a75c444b503060b2634968.zip
MAX_WORD should not be bigger than MAX_INT
Diffstat (limited to 'lgc.c')
-rw-r--r--lgc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lgc.c b/lgc.c
index 38cc50d3..21550bb7 100644
--- a/lgc.c
+++ b/lgc.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lgc.c,v 1.14 1997/12/17 20:48:58 roberto Exp roberto $ 2** $Id: lgc.c,v 1.15 1998/01/09 14:44:55 roberto Exp roberto $
3** Garbage Collector 3** Garbage Collector
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -41,7 +41,7 @@ int luaC_ref (TObject *o, int lock)
41 /* no more empty spaces */ { 41 /* no more empty spaces */ {
42 int oldSize = L->refSize; 42 int oldSize = L->refSize;
43 L->refSize = luaM_growvector(&L->refArray, L->refSize, struct ref, 43 L->refSize = luaM_growvector(&L->refArray, L->refSize, struct ref,
44 refEM, MAX_WORD); 44 refEM, MAX_INT);
45 for (ref=oldSize; ref<L->refSize; ref++) 45 for (ref=oldSize; ref<L->refSize; ref++)
46 L->refArray[ref].status = FREE; 46 L->refArray[ref].status = FREE;
47 ref = oldSize; 47 ref = oldSize;