shithub: freetype+ttf2subf

Download patch

ref: a11650d7faf4e91d6ad9aafb1bde5207c2c25124
parent: f8a4163a459e828a1b908b1f64737b2daab17299
author: Werner Lemberg <[email protected]>
date: Sun Nov 21 02:51:31 EST 2021

* src/truetype/ttinterp.c (Ins_MD): Avoid `FT_ABS`.

Reported as

  https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=38562

git/fs: mount .git/fs: mount/attach disallowed
--- a/src/truetype/ttinterp.c
+++ b/src/truetype/ttinterp.c
@@ -5003,9 +5003,9 @@
 
 #ifdef TT_SUPPORT_SUBPIXEL_HINTING_INFINALITY
     /* Disable Type 2 Vacuform Rounds - e.g. Arial Narrow */
-    if ( SUBPIXEL_HINTING_INFINALITY &&
-         exc->ignore_x_mode          &&
-         FT_ABS( D ) == 64           )
+    if ( SUBPIXEL_HINTING_INFINALITY         &&
+         exc->ignore_x_mode                  &&
+         ( D < 0 ? NEG_LONG( D ) : D ) == 64 )
       D += 1;
 #endif /* TT_SUPPORT_SUBPIXEL_HINTING_INFINALITY */