From 88b7b30b35362de445367cfd24994199dee3be2a Mon Sep 17 00:00:00 2001 From: Martin Date: Sat, 19 Oct 2024 18:21:43 +0200 Subject: [PATCH] fix https://github.com/gp48k/zmac/issues/7 Signed-off-by: Martin --- src/zmac.y | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/zmac.y b/src/zmac.y index 395cf2a..e08b24d 100644 --- a/src/zmac.y +++ b/src/zmac.y @@ -5661,7 +5661,7 @@ struct item *item_lookup(char *name, struct item *table, int table_size) while (*p) { char ch = *p++; if (ch >= 'A' && ch <= 'Z') ch += 'a' - 'A'; - hash += hash * 67 + ch - 113; + hash = hash * 67 + ch - 113; } hash %= table_size; ip = &table[hash];