Skip to content

Commit e34b6bd

Browse files
committed
Guarding.
1 parent ab77a5f commit e34b6bd

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/xorfilter/xor_binary_fuse_filter.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ size_t calculateSegmentLength(size_t arity, size_t size) {
2626
}
2727

2828
double calculateSizeFactor(size_t arity, size_t size) {
29+
if(size <= 2) { size = 2; }
2930
double sizeFactor;
3031
if (arity == 3) {
3132
sizeFactor = fmax(1.125, 0.875 + 0.25 * log(1000000) / log(size));

0 commit comments

Comments
 (0)