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

Commit fcb944ef authored by Manjeet Rulhania's avatar Manjeet Rulhania
Browse files

Synchronize when updating listeners during uninstall


Bug: 417779908
Test: presubmit
Flag: EXEMPT bug fix
Change-Id: I73fa5078572544ba1739d307f75e1013650d9594
parent 750ed031
Loading
Loading
Loading
Loading
+9 −7
Original line number Diff line number Diff line
@@ -64,6 +64,7 @@ public class OneTimePermissionUserManager {
        public void onReceive(Context context, Intent intent) {
            if (Intent.ACTION_UID_REMOVED.equals(intent.getAction())) {
                int uid = intent.getIntExtra(Intent.EXTRA_UID, -1);
                synchronized (mLock) {
                    PackageInactivityListener listener = mListeners.get(uid);
                    if (listener != null) {
                        if (DEBUG) {
@@ -74,6 +75,7 @@ public class OneTimePermissionUserManager {
                    }
               }
            }
        }
    };

    /** Maps the uid to the PackageInactivityListener */