[map] Fix size calculation
Don't know why I thought I should subtract one there...
This commit is contained in:
parent
ff92de766b
commit
b3d45de6cf
|
@ -90,7 +90,7 @@ struct hb_map_t
|
||||||
{
|
{
|
||||||
if (unlikely (in_error)) return false;
|
if (unlikely (in_error)) return false;
|
||||||
|
|
||||||
unsigned int power = _hb_bit_storage (population * 2 + 8) - 1;
|
unsigned int power = _hb_bit_storage (population * 2 + 8);
|
||||||
unsigned int new_size = 1u << power;
|
unsigned int new_size = 1u << power;
|
||||||
item_t *new_items = (item_t *) malloc ((size_t) new_size * sizeof (item_t));
|
item_t *new_items = (item_t *) malloc ((size_t) new_size * sizeof (item_t));
|
||||||
if (unlikely (!new_items))
|
if (unlikely (!new_items))
|
||||||
|
|
Loading…
Reference in New Issue