Re: hash tables with an ht_size < 16 can cause an endless loop

2015-05-23 Thread Paul Smith
On Sat, 2015-05-23 at 16:03 +0200, Peter Gijsels wrote: > When playing with the hash table implementation in GNU make 4.1, I > stumbled across the following bug: hash tables with an ht_size < 16 > can get stuck in an endless loop. For what it's worth, the hash.c implementation is taken almost verb

hash tables with an ht_size < 16 can cause an endless loop

2015-05-23 Thread Peter Gijsels
When playing with the hash table implementation in GNU make 4.1, I stumbled across the following bug: hash tables with an ht_size < 16 can get stuck in an endless loop. The problematic code is on hash.c:55 ht->ht_capacity = ht->ht_size - (ht->ht_size / 16); /* 93.75% loading factor */ If ht->