From fcbf14a0e52dafff260e4d753ff84a42953cea45 Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Tue, 25 Feb 2025 20:16:18 -0700 Subject: [PATCH] [CompositeGlyph] Adjust pre-allocation --- src/OT/glyf/CompositeGlyph.hh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/OT/glyf/CompositeGlyph.hh b/src/OT/glyf/CompositeGlyph.hh index 5c0ecd513..e2ec4a80e 100644 --- a/src/OT/glyf/CompositeGlyph.hh +++ b/src/OT/glyf/CompositeGlyph.hh @@ -143,7 +143,7 @@ struct CompositeGlyphRecord float matrix[4]; contour_point_t trans; get_transformation (matrix, trans); - if (unlikely (!points.alloc (points.length + 4))) return false; // For phantom points + if (unlikely (!points.alloc (points.length + 1 + 4))) return false; // For phantom points points.push (trans); return true; }