Don't attempt to preload fonts in isolated processes.

Isolated processes used to run external services have the package name
of the application which caused them to be started (i.e. the client
application bound to the service) in their ApplicationInfo's packageName
field, not the package name which is actually loaded in the current
process. This meant that the font preloading code used the manifest of
the client application to determine the resource ID for the preloaded
font list, but then looked up that resource ID in the service's APK,
which typically results in a crash as that resource ID is unlikely to
exist.

Avoid this case occurring by not doing font preloading in isolated
processes, which are not normally capable of displaying UI in any case
and so likely do not require it.

Bug: 70968451
Test: CtsWebkitTestCases
Change-Id: Id47e01aab28a6fd48f5928ce33d5060fb2717527
1 file changed