7068471: NPE in sun.font.FontConfigManager.getFontConfigFont() when libfontconfig.so is not installed
Reviewed-by: jgodinez, prr
This commit is contained in:
parent
c058d2d4c0
commit
4ea3a97967
@ -347,6 +347,11 @@ public class FontConfigManager {
|
||||
name = name.toLowerCase();
|
||||
|
||||
initFontConfigFonts(false);
|
||||
if (fontConfigFonts == null) {
|
||||
// This avoids an immediate NPE if fontconfig look up failed
|
||||
// but doesn't guarantee this is a recoverable situation.
|
||||
return null;
|
||||
}
|
||||
|
||||
FcCompFont fcInfo = null;
|
||||
for (int i=0; i<fontConfigFonts.length; i++) {
|
||||
|
Loading…
Reference in New Issue
Block a user