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

Commit c728241e authored by Song Chun Fan's avatar Song Chun Fan Committed by Automerger Merge Worker
Browse files

Merge "When the sharedUserSetting of the application on /system is different...

Merge "When the sharedUserSetting of the application on /system is different from the sharedUserSetting on /data, we should trust the sharedUserSetting on /system" am: b51e99de am: a1dd9bec am: 382b1220 am: aed29986 am: c5410045

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2481897



Change-Id: I93172f4f3dc5203e8500ebf912d886473b001588
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents fbfab93e c5410045
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -4277,10 +4277,14 @@ final class InstallPackageHelper {
                    deletePackageHelper.deletePackageLIF(parsedPackage.getPackageName(), null, true,
                            mPm.mUserManager.getUserIds(), 0, null, false);
                }
            } else if (newPkgVersionGreater) {
            } else if (newPkgVersionGreater || newSharedUserSetting) {
                // The application on /system is newer than the application on /data.
                // Simply remove the application on /data [keeping application data]
                // and replace it with the version on /system.
                // Also, if the sharedUserSetting of the application on /system is different
                // from the sharedUserSetting on data, we should trust the sharedUserSetting
                // on /system, even if the application version on /system is smaller than
                // the version on /data.
                logCriticalInfo(Log.WARN,
                        "System package enabled;"
                                + " name: " + pkgSetting.getPackageName()