benchmarks/eina: fix possible div by zero in ecore_hash
Summary: CID 1400768 Reviewers: devilhorns Reviewed By: devilhorns Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D10397
This commit is contained in:
parent
36c5f1026f
commit
d417868c90
|
@ -416,6 +416,7 @@ ecore_hash_dump_stats(Ecore_Hash *hash)
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
double variance, sum_n_2 = 0, sum_n = 0;
|
double variance, sum_n_2 = 0, sum_n = 0;
|
||||||
|
|
||||||
|
if (!hash->size) return;
|
||||||
for (i = 0; i < ecore_prime_table[hash->size]; i++)
|
for (i = 0; i < ecore_prime_table[hash->size]; i++)
|
||||||
{
|
{
|
||||||
if (hash->buckets[i])
|
if (hash->buckets[i])
|
||||||
|
|
Loading…
Reference in New Issue