From 0d6ba42e4997e0a440f9eb64b269e81e31f48d38 Mon Sep 17 00:00:00 2001 From: Gerd Moellmann Date: Tue, 29 Feb 2000 09:30:43 +0000 Subject: [PATCH] (maybe_resize_hash_table): Handle case of new size coming out as being the same as old size. --- src/fns.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/fns.c b/src/fns.c index e6ff6835947..9c06764bdb3 100644 --- a/src/fns.c +++ b/src/fns.c @@ -3826,6 +3826,7 @@ maybe_resize_hash_table (h) new_size = old_size + XFASTINT (h->rehash_size); else new_size = old_size * XFLOATINT (h->rehash_size); + new_size = max (old_size + 1, new_size); index_size = next_almost_prime (new_size / XFLOATINT (h->rehash_threshold)); if (max (index_size, 2 * new_size) & ~VALMASK) -- 2.39.5