Remove unnecessary condition in _dictExpandIfNeeded (dict.c)
This commit is contained in:
parent
c87a40897c
commit
dee0b939fc
@ -621,8 +621,7 @@ static int _dictExpandIfNeeded(dict *d)
|
|||||||
(dict_can_resize ||
|
(dict_can_resize ||
|
||||||
d->ht[0].used/d->ht[0].size > dict_force_resize_ratio))
|
d->ht[0].used/d->ht[0].size > dict_force_resize_ratio))
|
||||||
{
|
{
|
||||||
return dictExpand(d, ((d->ht[0].size > d->ht[0].used) ?
|
return dictExpand(d, d->ht[0].used*2);
|
||||||
d->ht[0].size : d->ht[0].used)*2);
|
|
||||||
}
|
}
|
||||||
return DICT_OK;
|
return DICT_OK;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user