diff options
author | dormando <dormando@rydia.net> | 2017-08-27 11:51:27 -0700 |
---|---|---|
committer | dormando <dormando@rydia.net> | 2017-08-27 11:51:27 -0700 |
commit | c5b3ecba410477fc2ada57b77aa84d53694ed5a5 (patch) | |
tree | cabf0b13235aa6c8815e95705e72613952d2f18c /assoc.c | |
parent | 265d407fd817978f6e245a19eaca49a3c628fcf4 (diff) | |
download | memcached-c5b3ecba410477fc2ada57b77aa84d53694ed5a5.tar.gz |
don't create hashtables larger than 32bit
most other stats related to items should be 64bit, so the totals should be
ableable to go higher until we get 64bit hash tables.
Diffstat (limited to 'assoc.c')
-rw-r--r-- | assoc.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -170,7 +170,8 @@ int assoc_insert(item *it, const uint32_t hv) { pthread_mutex_lock(&hash_items_counter_lock); hash_items++; - if (! expanding && hash_items > (hashsize(hashpower) * 3) / 2) { + if (! expanding && hash_items > (hashsize(hashpower) * 3) / 2 && + hashpower < HASHPOWER_MAX) { assoc_start_expand(); } pthread_mutex_unlock(&hash_items_counter_lock); |