From 04ebb2a000ee40df2a9900198ec62d79af745b1f Mon Sep 17 00:00:00 2001 From: Werner Lemberg Date: Tue, 17 Sep 2019 19:46:59 +0200 Subject: [PATCH] * src/otvalid/otvcommon.c (otv_Coverage_get_last): Guard `count'. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Problem reported by Marc Schönefeld . --- ChangeLog | 6 ++++++ src/otvalid/otvcommn.c | 3 +++ 2 files changed, 9 insertions(+) diff --git a/ChangeLog b/ChangeLog index 03292f1ac..bed580216 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2019-09-17 Werner Lemberg + + * src/otvalid/otvcommon.c (otv_Coverage_get_last): Guard `count'. + + Problem reported by Marc Schönefeld . + 2019-09-17 Werner Lemberg * src/sfnt/sfwoff2.c (woff2_open_font): Check table index. diff --git a/src/otvalid/otvcommn.c b/src/otvalid/otvcommn.c index 5ed172350..3bd99f504 100644 --- a/src/otvalid/otvcommn.c +++ b/src/otvalid/otvcommn.c @@ -151,6 +151,9 @@ FT_UInt result = 0; + if ( !count ) + return result; + switch ( CoverageFormat ) { case 1: