aboutsummaryrefslogtreecommitdiff
path: root/ltable.c
diff options
context:
space:
mode:
Diffstat (limited to 'ltable.c')
-rw-r--r--ltable.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ltable.c b/ltable.c
index 3683fe60..adccb0a7 100644
--- a/ltable.c
+++ b/ltable.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: ltable.c,v 2.67 2011/11/30 12:41:45 roberto Exp roberto $ 2** $Id: ltable.c,v 2.69 2012/01/25 21:05:40 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*/
@@ -101,7 +101,7 @@ static Node *mainposition (const Table *t, const TValue *key) {
101 case LUA_TLNGSTR: { 101 case LUA_TLNGSTR: {
102 TString *s = rawtsvalue(key); 102 TString *s = rawtsvalue(key);
103 if (s->tsv.extra == 0) { /* no hash? */ 103 if (s->tsv.extra == 0) { /* no hash? */
104 s->tsv.hash = luaS_hash(getstr(s), s->tsv.len); 104 s->tsv.hash = luaS_hash(getstr(s), s->tsv.len, s->tsv.hash);
105 s->tsv.extra = 1; /* now it has its hash */ 105 s->tsv.extra = 1; /* now it has its hash */
106 } 106 }
107 return hashstr(t, rawtsvalue(key)); 107 return hashstr(t, rawtsvalue(key));