Merge "Correct locking in PackageManagerService" into sc-dev
This commit is contained in:
@@ -26493,7 +26493,7 @@ public class PackageManagerService extends IPackageManager.Stub
|
|||||||
}
|
}
|
||||||
|
|
||||||
boolean readPermissionStateForUser(@UserIdInt int userId) {
|
boolean readPermissionStateForUser(@UserIdInt int userId) {
|
||||||
synchronized (mPackages) {
|
synchronized (mLock) {
|
||||||
mPermissionManager.writeLegacyPermissionStateTEMP();
|
mPermissionManager.writeLegacyPermissionStateTEMP();
|
||||||
mSettings.readPermissionStateForUserSyncLPr(userId);
|
mSettings.readPermissionStateForUserSyncLPr(userId);
|
||||||
mPermissionManager.readLegacyPermissionStateTEMP();
|
mPermissionManager.readLegacyPermissionStateTEMP();
|
||||||
@@ -26569,7 +26569,7 @@ public class PackageManagerService extends IPackageManager.Stub
|
|||||||
if (packageName == null || alias == null) {
|
if (packageName == null || alias == null) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
synchronized(mLock) {
|
synchronized (mLock) {
|
||||||
final AndroidPackage pkg = mPackages.get(packageName);
|
final AndroidPackage pkg = mPackages.get(packageName);
|
||||||
if (pkg == null
|
if (pkg == null
|
||||||
|| shouldFilterApplicationLocked(getPackageSetting(pkg.getPackageName()),
|
|| shouldFilterApplicationLocked(getPackageSetting(pkg.getPackageName()),
|
||||||
@@ -26616,7 +26616,7 @@ public class PackageManagerService extends IPackageManager.Stub
|
|||||||
if (packageName == null || ks == null) {
|
if (packageName == null || ks == null) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
synchronized(mLock) {
|
synchronized (mLock) {
|
||||||
final AndroidPackage pkg = mPackages.get(packageName);
|
final AndroidPackage pkg = mPackages.get(packageName);
|
||||||
if (pkg == null
|
if (pkg == null
|
||||||
|| shouldFilterApplicationLocked(getPackageSetting(pkg.getPackageName()),
|
|| shouldFilterApplicationLocked(getPackageSetting(pkg.getPackageName()),
|
||||||
|
|||||||
Reference in New Issue
Block a user