|
@@ -0,0 +1,33 @@
|
|
|
+From 73720c7c9958e87b3d134a7574d1720ad2d24442 Mon Sep 17 00:00:00 2001
|
|
|
+From: Alexei Podtelezhnikov <apodtele@gmail.com>
|
|
|
+Date: Sun, 23 Jun 2024 10:58:00 -0400
|
|
|
+Subject: [PATCH] * src/truetype/ttgload.c (load_truetype_glyph): Unsigned fix.
|
|
|
+
|
|
|
+CVE: CVE-2025-27363
|
|
|
+Upstream-Status: Backport [https://gitlab.freedesktop.org/freetype/freetype/-/commit/73720c7c9958e87b3d134a7574d1720ad2d24442]
|
|
|
+Signed-off-by: Peter Marko <peter.marko@siemens.com>
|
|
|
+---
|
|
|
+ src/truetype/ttgload.c | 4 ++--
|
|
|
+ 1 file changed, 2 insertions(+), 2 deletions(-)
|
|
|
+
|
|
|
+diff --git a/src/truetype/ttgload.c b/src/truetype/ttgload.c
|
|
|
+index 8cddc394c..b656ccf04 100644
|
|
|
+--- a/src/truetype/ttgload.c
|
|
|
++++ b/src/truetype/ttgload.c
|
|
|
+@@ -1741,14 +1741,14 @@
|
|
|
+ if ( FT_IS_NAMED_INSTANCE( FT_FACE( face ) ) ||
|
|
|
+ FT_IS_VARIATION( FT_FACE( face ) ) )
|
|
|
+ {
|
|
|
+- short i, limit;
|
|
|
++ FT_UShort i, limit;
|
|
|
+ FT_SubGlyph subglyph;
|
|
|
+
|
|
|
+ FT_Outline outline = { 0, 0, NULL, NULL, NULL, 0 };
|
|
|
+ FT_Vector* unrounded = NULL;
|
|
|
+
|
|
|
+
|
|
|
+- limit = (short)gloader->current.num_subglyphs;
|
|
|
++ limit = (FT_UShort)gloader->current.num_subglyphs;
|
|
|
+
|
|
|
+ /* construct an outline structure for */
|
|
|
+ /* communication with `TT_Vary_Apply_Glyph_Deltas' */
|