[cff] Fix segfault on missing `psaux' (#52218) * src/cff/cffload.c (cff_done_blend): Add a check for possible nullptr. * modules.cfg: Update dependency list.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
diff --git a/ChangeLog b/ChangeLog
index b7db5d9..160f445 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2017-10-12 Ewald Hew <ewaldhew@gmail.com>
+
+ [cff] Fix segfault on missing `psaux' (#52218)
+
+ * src/cff/cffload.c (cff_done_blend): Add a check for possible nullptr.
+
+ * modules.cfg: Update dependency list.
+
2017-10-15 Alexei Podtelezhnikov <apodtele@gmail.com>
[base, cff] Fix MSVC warnings.
diff --git a/modules.cfg b/modules.cfg
index 517111e..56a2340 100644
--- a/modules.cfg
+++ b/modules.cfg
@@ -42,7 +42,7 @@ FONT_MODULES += type1
# CFF/OpenType font driver.
#
-# This driver needs the `sfnt', `pshinter', and `psnames' modules.
+# This driver needs the `sfnt', `psaux', `pshinter', and `psnames' modules.
FONT_MODULES += cff
# Type 1 CID-keyed font driver.
diff --git a/src/cff/cffload.c b/src/cff/cffload.c
index 069e904..e8479d4 100644
--- a/src/cff/cffload.c
+++ b/src/cff/cffload.c
@@ -1595,7 +1595,8 @@
FT_Service_MultiMasters mm = (FT_Service_MultiMasters)face->mm;
- mm->done_blend( FT_FACE( face ) );
+ if (mm)
+ mm->done_blend( FT_FACE( face ) );
}
#endif /* TT_CONFIG_OPTION_GX_VAR_SUPPORT */