From d0ee5a452f057386d5dbffef1e8f7912fec8537c Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Sun, 11 Dec 2022 13:13:35 -0700 Subject: [PATCH] [COLR] Return false from get_extents if table version not 1 --- src/hb-ot-color-colr-table.hh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/hb-ot-color-colr-table.hh b/src/hb-ot-color-colr-table.hh index 1bec3f327..2fcf7afa6 100644 --- a/src/hb-ot-color-colr-table.hh +++ b/src/hb-ot-color-colr-table.hh @@ -1547,6 +1547,8 @@ struct COLR bool get_extents (hb_font_t *font, hb_codepoint_t glyph, hb_glyph_extents_t *extents) const { + if (version != 1) + return false; if ((this+clipList).get_extents (glyph, extents)) { extents->x_bearing = font->em_scale_x (extents->x_bearing);