diff --git a/src/hb-map-private.hh b/src/hb-map-private.hh index 07d5d0dab356039eb04373fec7c43748c13d5d48..7611021a8c3aaf6cb086626c4d2aa4c46bcf194a 100644 --- a/src/hb-map-private.hh +++ b/src/hb-map-private.hh @@ -132,12 +132,11 @@ struct hb_map_t return; /* Trying to delete non-existent key. */ /* Accounting. */ - if (items[i].is_tombstone ()) - occupancy--; - else if (!items[i].is_unused ()) + if (!items[i].is_unused ()) { - population--; occupancy--; + if (items[i].value != INVALID) + population--; } occupancy++; if (value != INVALID)