commit d989dd8885b2f29e01cad66bc8e9d64355c003c5
Author: Kevin Kofler <kevin.kofler(a)chello.at>
Date: Wed Jun 7 01:07:39 2017 +0200
Add freetype-2.8-loop-counter.patch from Fedora freetype (rh#1456585)
* Tue Jun 06 2017 Kevin Kofler <Kevin(a)tigcc.ticalc.org> 2.8-3
- Add freetype-2.8-loop-counter.patch from Fedora freetype:
Adjust loop counter maximum for TrueType fonts (rh#1456585)
freetype-2.8-loop-counter.patch | 36 ++++++++++++++++++++++++++++++++++++
freetype-freeworld.spec | 11 ++++++++++-
2 files changed, 46 insertions(+), 1 deletion(-)
---
diff --git a/freetype-2.8-loop-counter.patch b/freetype-2.8-loop-counter.patch
new file mode 100644
index 0000000..61e9052
--- /dev/null
+++ b/freetype-2.8-loop-counter.patch
@@ -0,0 +1,36 @@
+From 8d435c463d22f6de35015b244d6f9bb433beb7e6 Mon Sep 17 00:00:00 2001
+From: Werner Lemberg <wl(a)gnu.org>
+Date: Thu, 1 Jun 2017 07:09:44 +0200
+Subject: [PATCH] * src/truetype/ttinterp.c (TT_RunIns): Adjust loop counter
+ again.
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Problem reported by Marek Kašík <mkasik(a)redhat.com>.
+
+The problematic font that exceeds the old limit is Padauk-Bold,
+version 3.002, containing bytecode generated by a buggy version of
+ttfautohint.
+---
+ ChangeLog | 10 ++++++++++
+ src/truetype/ttinterp.c | 3 +--
+ 2 files changed, 11 insertions(+), 2 deletions(-)
+
+diff --git a/src/truetype/ttinterp.c b/src/truetype/ttinterp.c
+index 0c48c256..775d1104 100644
+--- a/src/truetype/ttinterp.c
++++ b/src/truetype/ttinterp.c
+@@ -7649,8 +7649,7 @@
+ FT_MAX( 50,
+ exc->cvtSize / 10 );
+ else
+- exc->loopcall_counter_max = FT_MAX( 100,
+- 10 * exc->cvtSize );
++ exc->loopcall_counter_max = 300 + 8 * exc->cvtSize;
+
+ /* as a protection against an unreasonable number of CVT entries */
+ /* we assume at most 100 control values per glyph for the counter */
+--
+2.13.0
+
diff --git a/freetype-freeworld.spec b/freetype-freeworld.spec
index a81bf67..2191a88 100644
--- a/freetype-freeworld.spec
+++ b/freetype-freeworld.spec
@@ -1,7 +1,7 @@
Summary: A free and portable font rendering engine
Name: freetype-freeworld
Version: 2.8
-Release: 2%{?dist}
+Release: 3%{?dist}
License: (FTL or GPLv2+) and BSD and MIT and Public Domain and zlib with acknowledgement
URL:
http://www.freetype.org
Source:
http://download.savannah.gnu.org/releases/freetype/freetype-%{version}.ta...
@@ -15,6 +15,10 @@ Patch1: freetype-2.2.1-enable-valid.patch
#
https://bugzilla.redhat.com/show_bug.cgi?id=1451795
Patch4: freetype-2.8-pcf-encoding.patch
+# Adjust loop counter maximum for TrueType fonts
+#
https://bugzilla.redhat.com/show_bug.cgi?id=1456585
+Patch5: freetype-2.8-loop-counter.patch
+
## Security fixes:
# None yet
@@ -47,6 +51,7 @@ It transparently overrides the system library using ld.so.conf.d.
%patch1 -p1 -b .enable-valid
%patch4 -p1 -b .pcf-encoding
+%patch5 -p1 -b .loop-counter
%build
%configure --disable-static \
@@ -90,6 +95,10 @@ echo "%{_libdir}/%{name}" \
%config(noreplace) %{_sysconfdir}/ld.so.conf.d/%{name}-%{_arch}.conf
%changelog
+* Tue Jun 06 2017 Kevin Kofler <Kevin(a)tigcc.ticalc.org> 2.8-3
+- Add freetype-2.8-loop-counter.patch from Fedora freetype:
+ Adjust loop counter maximum for TrueType fonts (rh#1456585)
+
* Sun May 28 2017 Kevin Kofler <Kevin(a)tigcc.ticalc.org> 2.8-2
- Add freetype-2.8-pcf-encoding.patch from Fedora freetype: Accept
ISO646.1991-IRV as a Unicode charmap in PCF and BDF drivers (rh#1451795)