From: Tom Tromey Date: Sat, 20 Jan 2018 22:09:40 +0000 (-0700) Subject: fix possible infinite loop in find_filename_hash_slot X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=72c8dee162db7cc4d6405d97a097875ff0cd2f85;p=emacs.git fix possible infinite loop in find_filename_hash_slot --- diff --git a/lib-src/etags.c b/lib-src/etags.c index f7632f3275c..982e3a0a1e5 100644 --- a/lib-src/etags.c +++ b/lib-src/etags.c @@ -7683,8 +7683,7 @@ find_filename_hash_slot (const char *filename) || streq (filename_hash_table[index], filename)) return &filename_hash_table[index]; - /* Add 1 because, if VAL==0, we won't advance. */ - index = (index + val + 1) % filename_hash_size; + index = (index + 3) % filename_hash_size; } }