am 073bfb9b: am ce68917c: Merge "Ensure per package and per UID state share same package settings." into mnc-dev
* commit '073bfb9bec7bc407c50a23a2317852cb0d69599b': Ensure per package and per UID state share same package settings.
This commit is contained in:
@@ -616,6 +616,7 @@ final class Settings {
|
|||||||
p.sharedUser = origPackage.sharedUser;
|
p.sharedUser = origPackage.sharedUser;
|
||||||
p.appId = origPackage.appId;
|
p.appId = origPackage.appId;
|
||||||
p.origPackage = origPackage;
|
p.origPackage = origPackage;
|
||||||
|
p.getPermissionsState().copyFrom(origPackage.getPermissionsState());
|
||||||
mRenamedPackages.put(name, origPackage.name);
|
mRenamedPackages.put(name, origPackage.name);
|
||||||
name = origPackage.name;
|
name = origPackage.name;
|
||||||
// Update new package state.
|
// Update new package state.
|
||||||
@@ -815,6 +816,20 @@ final class Settings {
|
|||||||
p.sharedUser = sharedUser;
|
p.sharedUser = sharedUser;
|
||||||
p.appId = sharedUser.userId;
|
p.appId = sharedUser.userId;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// If the we know about this user id, we have to update it as it
|
||||||
|
// has to point to the same PackageSetting instance as the package.
|
||||||
|
Object userIdPs = getUserIdLPr(p.appId);
|
||||||
|
if (sharedUser == null) {
|
||||||
|
if (userIdPs != null && userIdPs != p) {
|
||||||
|
replaceUserIdLPw(p.appId, p);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if (userIdPs != null && userIdPs != sharedUser) {
|
||||||
|
replaceUserIdLPw(p.appId, sharedUser);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
IntentFilterVerificationInfo ivi = mRestoredIntentFilterVerifications.get(name);
|
IntentFilterVerificationInfo ivi = mRestoredIntentFilterVerifications.get(name);
|
||||||
if (ivi != null) {
|
if (ivi != null) {
|
||||||
if (DEBUG_DOMAIN_VERIFICATION) {
|
if (DEBUG_DOMAIN_VERIFICATION) {
|
||||||
|
|||||||
Reference in New Issue
Block a user