- Notifications
You must be signed in to change notification settings - Fork5
Commitfa09f89
committed
Clamp adjusted ndistinct to positive integer in estimate_hash_bucketsize().
This avoids a possible divide-by-zero in the following calculation,and rounding the number to an integer seems like saner behavior anyway.Assuming IEEE math, the division would yield +Infinity which would getreplaced by 1.0 at the bottom of the function, so nothing reallyinteresting would ensue; but avoiding divide-by-zero seems like agood idea on general principles.Per report from Piotr Stefaniak. No back-patch since this seemsmostly cosmetic.1 parent408f043 commitfa09f89
1 file changed
+3
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3541 | 3541 | | |
3542 | 3542 | | |
3543 | 3543 | | |
| 3544 | + | |
3544 | 3545 | | |
| 3546 | + | |
| 3547 | + | |
3545 | 3548 | | |
3546 | 3549 | | |
3547 | 3550 | | |
| |||
0 commit comments
Comments
(0)