aboutsummaryrefslogtreecommitdiff
path: root/ltable.c
diff options
context:
space:
mode:
Diffstat (limited to 'ltable.c')
-rw-r--r--ltable.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/ltable.c b/ltable.c
index 85cc6218..73a6011e 100644
--- a/ltable.c
+++ b/ltable.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: ltable.c,v 1.20 1999/01/25 17:41:19 roberto Exp roberto $ 2** $Id: ltable.c,v 1.21 1999/02/23 14:57:28 roberto Exp roberto $
3** Lua tables (hash) 3** Lua tables (hash)
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -140,7 +140,8 @@ void luaH_set (Hash *t, TObject *ref, TObject *val) {
140 if (ttype(ref(n)) != LUA_T_NIL) 140 if (ttype(ref(n)) != LUA_T_NIL)
141 *val(n) = *val; 141 *val(n) = *val;
142 else { 142 else {
143 TObject buff = *val; /* rehash may invalidate this address */ 143 TObject buff;
144 buff = *val; /* rehash may invalidate this address */
144 if ((long)nuse(t)*3L > (long)nhash(t)*2L) { 145 if ((long)nuse(t)*3L > (long)nhash(t)*2L) {
145 rehash(t); 146 rehash(t);
146 n = luaH_present(t, ref); 147 n = luaH_present(t, ref);