From 1e9229f0fcb46fd4cd8e0fdc48fb4a44ddb7a8a1 Mon Sep 17 00:00:00 2001 From: John Tytgat Date: Wed, 9 Oct 2019 15:37:19 +0200 Subject: [PATCH] [cff] Fix FT_FACE_FLAG_GLYPH_NAMES for CFF2 based fonts (#57023). * src/cff/cffobjs.c (cff_face_init): Don't set FT_FACE_FLAG_GLYPH_NAMES for CFF2 based fonts. --- ChangeLog | 7 +++++++ src/cff/cffobjs.c | 6 +++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index eaaa21e45..8fad2ed9c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2019-10-09 John Tytgat + + [cff] Fix FT_FACE_FLAG_GLYPH_NAMES for CFF2 based fonts (#57023). + + * src/cff/cffobjs.c (cff_face_init): Don't set FT_FACE_FLAG_GLYPH_NAMES + for CFF2 based fonts. + 2019-10-08 Werner Lemberg [woff2] Fix SFNT table checks. diff --git a/src/cff/cffobjs.c b/src/cff/cffobjs.c index f76245f30..2aad36337 100644 --- a/src/cff/cffobjs.c +++ b/src/cff/cffobjs.c @@ -1018,9 +1018,9 @@ } #ifndef FT_CONFIG_OPTION_NO_GLYPH_NAMES - /* CID-keyed CFF fonts don't have glyph names -- the SFNT loader */ - /* has unset this flag because of the 3.0 `post' table. */ - if ( dict->cid_registry == 0xFFFFU ) + /* CID-keyed CFF or CFF2 fonts don't have glyph names -- the SFNT */ + /* loader has unset this flag because of the 3.0 `post' table. */ + if ( dict->cid_registry == 0xFFFFU && !cff2 ) cffface->face_flags |= FT_FACE_FLAG_GLYPH_NAMES; #endif