summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--map.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/map.c b/map.c
index de8aadb..c720bbc 100644
--- a/map.c
+++ b/map.c
@@ -247,7 +247,7 @@ static size_t fetch_set_idx(
if (offset >= set->__num_buckets) return set->__num_buckets;
i++;
offset = i * i;
- idx = base + offset;
+ idx = (base + offset) % set->__num_buckets;
}
}