[repacker] always duplicate classDef2 when splitting a PairPos2.

Splits are done in a way that it shouldn't be possible to share the classDef2 between split PairPos2's so pre-emptively duplicate it.
This commit is contained in:
Garret Rieger 2022-08-03 21:01:23 +00:00
parent 6be152420f
commit 60d6ffb375
2 changed files with 2 additions and 1 deletions

View File

@ -381,6 +381,7 @@ struct PairPosFormat2 : public OT::Layout::GPOS_impl::PairPosFormat2_4<SmallType
class_def_link->objidx = class_def_2_id;
class_def_link->position = 10;
split_context.c.graph.vertices_[class_def_2_id].parents.push (pair_pos_prime_id);
split_context.c.graph.duplicate (pair_pos_prime_id, class_def_2_id);
return pair_pos_prime_id;
}

View File

@ -1211,7 +1211,7 @@ populate_serializer_with_large_pair_pos_2 (hb_serialize_context_t* c,
5 + num_class_1 - 1,
c);
pair_pos_2[i] = add_pair_pos_2 (i * num_class_1,
pair_pos_2[i] = add_pair_pos_2 (1 + i * num_class_1,
coverage[i],
class_def_1[i], num_class_1,
class_def_2[i], num_class_2,