Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 099da656 authored by Ivan Chiang's avatar Ivan Chiang
Browse files

Don't create cache when doing Apex PreRebootVerification

When StagingManager uses PackageParser2 to parse the APEX files during
pre-reboot verification with the parse flag PackageManager.GET_META_DATA,
it creates the caches of them. But, the caches are not used. Pass the
"null" instead of mCacheDir to avoid creating the caches.

Test: manual
Fix: 153618582
Change-Id: I40676082fc98d87ad2ad9fc94d02903afe0243d4
parent e6bd8505
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -3576,7 +3576,8 @@ public class PackageManagerService extends IPackageManager.Stub
            // Prepare a supplier of package parser for the staging manager to parse apex file
            // during the staging installation.
            final Supplier<PackageParser2> apexParserSupplier = () -> new PackageParser2(
                    mSeparateProcesses, mOnlyCore, mMetrics, mCacheDir, mPackageParserCallback);
                    mSeparateProcesses, mOnlyCore, mMetrics, null /* cacheDir */,
                    mPackageParserCallback);
            mInstallerService = new PackageInstallerService(mContext, this, apexParserSupplier);
            final Pair<ComponentName, String> instantAppResolverComponent =
                    getInstantAppResolverLPr();