Load preinstalled sytem font if fs-verity is not supported
Some form factor doesn't support fs-verity and it ends up with NPE during boot because of empty system font map. To work on such environment, load preinstalled system font before serializing system font map. Bug: N/A Test: N/A Change-Id: Ibc4d512e1a70d9e7be889ea7b1e6afa5e45b1bbb
This commit is contained in:
@@ -269,6 +269,9 @@ public final class FontManagerService extends IFontManager.Stub {
|
||||
synchronized (mUpdatableFontDirLock) {
|
||||
mUpdatableFontDir = createUpdatableFontDir();
|
||||
if (mUpdatableFontDir == null) {
|
||||
// If fs-verity is not supported, load preinstalled system font map and use it for
|
||||
// all apps.
|
||||
Typeface.loadPreinstalledSystemFontMap();
|
||||
setSerializedFontMap(serializeSystemServerFontMap());
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user