From 5cf423733305cd63e8b604e50dcb40f967dec71f Mon Sep 17 00:00:00 2001 From: Lee Salzman Date: Fri, 1 Jun 2018 15:39:50 -0400 Subject: [PATCH] Bug 1464094 - follow-up - check that dlsym succeeded in ApplyVariations. r=me MozReview-Commit-ID: 5lrrnFVKMS0 --- gfx/2d/ScaledFontFontconfig.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gfx/2d/ScaledFontFontconfig.cpp b/gfx/2d/ScaledFontFontconfig.cpp index 04d4e16ea30d..27256d36f7ee 100644 --- a/gfx/2d/ScaledFontFontconfig.cpp +++ b/gfx/2d/ScaledFontFontconfig.cpp @@ -589,6 +589,10 @@ ScaledFontFontconfig::ApplyVariations(const FontVariation* aVariations, setCoords = (SetVarDesignCoordsFunc)dlsym(RTLD_DEFAULT, "FT_Set_Var_Design_Coordinates"); } + if (!setCoords) { + return; + } + cairo_scaled_font_t* sf = GetCairoScaledFont(); FT_Face face = cairo_ft_scaled_font_lock_face(sf); if (face && face->face_flags & FT_FACE_FLAG_MULTIPLE_MASTERS) {