未验证 提交 3a93cbee 编写于 作者: A Alex Duan 提交者: GitHub

Merge pull request #8376 from mohitsaxenaknoldus/issue8386

Adding condition to check for Zero values during division or modulo by float zero
......@@ -296,7 +296,7 @@ double tdigestQuantile(TDigest *t, double q) {
a = b;
right = t->max;
if (idx < weight_so_far + a->weight) {
if (idx < weight_so_far + a->weight && a->weight != 0) {
double p = (idx - weight_so_far) / a->weight;
return left * (1 - p) + right * p;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册