fuzz: extend fuzzing coverage

This commit is contained in:
Nardi Ivan
2023-09-16 11:26:11 +02:00
committed by Ivan Nardi
parent 0828dff3ac
commit 70814002a9
9 changed files with 107 additions and 18 deletions
+1 -1
View File
@@ -216,7 +216,7 @@ static inline bool binary_fuse8_allocate(uint32_t size,
filter->SegmentLength = 262144;
}
filter->SegmentLengthMask = filter->SegmentLength - 1;
double sizeFactor = binary_fuse_calculate_size_factor(arity, size);
double sizeFactor = size <= 1 ? 0 : binary_fuse_calculate_size_factor(arity, size);
uint32_t capacity = size <= 1 ? 0 : (uint32_t)(round((double)size * sizeFactor));
uint32_t initSegmentCount =
(capacity + filter->SegmentLength - 1) / filter->SegmentLength -