Merge "Fix the scanning on non-APEX devices." am: 6589fd106d
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1889637 Change-Id: I96575cfdec30d5b9e7183d6559fc223c359b34d7
This commit is contained in:
@ -21917,8 +21917,10 @@ public class PackageManagerService extends IPackageManager.Stub
|
||||
ApexManager.ActiveApexInfo apexInfo) {
|
||||
for (int i = 0, size = SYSTEM_PARTITIONS.size(); i < size; i++) {
|
||||
ScanPartition sp = SYSTEM_PARTITIONS.get(i);
|
||||
if (apexInfo.preInstalledApexPath.getAbsolutePath().startsWith(
|
||||
sp.getFolder().getAbsolutePath() + File.separator)) {
|
||||
if (apexInfo.preInstalledApexPath.getAbsolutePath().equals(
|
||||
sp.getFolder().getAbsolutePath())
|
||||
|| apexInfo.preInstalledApexPath.getAbsolutePath().startsWith(
|
||||
sp.getFolder().getAbsolutePath() + File.separator)) {
|
||||
return new ScanPartition(apexInfo.apexDirectory, sp, SCAN_AS_APK_IN_APEX);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user