Blame SOURCES/freetype-2.8-loop-counter.patch

4c33b1
From 8d435c463d22f6de35015b244d6f9bb433beb7e6 Mon Sep 17 00:00:00 2001
4c33b1
From: Werner Lemberg <wl@gnu.org>
4c33b1
Date: Thu, 1 Jun 2017 07:09:44 +0200
4c33b1
Subject: [PATCH] * src/truetype/ttinterp.c (TT_RunIns): Adjust loop counter
4c33b1
 again.
4c33b1
MIME-Version: 1.0
4c33b1
Content-Type: text/plain; charset=UTF-8
4c33b1
Content-Transfer-Encoding: 8bit
4c33b1
4c33b1
Problem reported by Marek Kašík <mkasik@redhat.com>.
4c33b1
4c33b1
The problematic font that exceeds the old limit is Padauk-Bold,
4c33b1
version 3.002, containing bytecode generated by a buggy version of
4c33b1
ttfautohint.
4c33b1
---
4c33b1
 ChangeLog               | 10 ++++++++++
4c33b1
 src/truetype/ttinterp.c |  3 +--
4c33b1
 2 files changed, 11 insertions(+), 2 deletions(-)
4c33b1
4c33b1
diff --git a/src/truetype/ttinterp.c b/src/truetype/ttinterp.c
4c33b1
index 0c48c256..775d1104 100644
4c33b1
--- a/src/truetype/ttinterp.c
4c33b1
+++ b/src/truetype/ttinterp.c
4c33b1
@@ -7649,8 +7649,7 @@
4c33b1
                                   FT_MAX( 50,
4c33b1
                                           exc->cvtSize / 10 );
4c33b1
     else
4c33b1
-      exc->loopcall_counter_max = FT_MAX( 100,
4c33b1
-                                          10 * exc->cvtSize );
4c33b1
+      exc->loopcall_counter_max = 300 + 8 * exc->cvtSize;
4c33b1
 
4c33b1
     /* as a protection against an unreasonable number of CVT entries  */
4c33b1
     /* we assume at most 100 control values per glyph for the counter */
4c33b1
-- 
4c33b1
2.13.0
4c33b1