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

Commit 65877abd authored by Ryan Mitchell's avatar Ryan Mitchell Committed by Android (Google) Code Review
Browse files

Merge "Fix forgetAllPackageInfos OutOfBoundsException" into sc-dev

parents e114b8f4 6f24df4a
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -1341,7 +1341,9 @@ public final class OverlayManagerService extends SystemService {
        }

        public void forgetAllPackageInfos(final int userId) {
            for (int i = 0, n = mCache.size(); i < n; i++) {
            // Iterate in reverse order since removing the package in all users will remove the
            // package from the cache.
            for (int i = mCache.size() - 1; i >= 0; i--) {
                removePackageUser(mCache.valueAt(i), userId);
            }
        }