From 002f248ade44e83258b36bd0bd1bc2e3605dcc7a Mon Sep 17 00:00:00 2001 From: Ali Gholami Rudi Date: Thu, 28 Dec 2017 12:25:35 +0330 Subject: [PATCH] dict: reduce table size --- dict.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dict.c b/dict.c index 331e837..8866e65 100644 --- a/dict.c +++ b/dict.c @@ -61,7 +61,7 @@ static int dict_hash(struct dict *d, char *key) int i = d->hashlen; while (--i > 0 && *key) hash = (hash << 5) + hash + (unsigned char) *key++; - return hash & 0xffff; + return hash & 0x3ff; } void dict_put(struct dict *d, char *key, int val) -- 2.11.4.GIT