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

Commit 876d11e3 authored by Sunny Goyal's avatar Sunny Goyal
Browse files

Null check in flushInvalidIcons

> Icons in a CacheEntry can be null, for a restored app. No
need to flush such entries on DeviceProfileChange

Bug: 17489687
Change-Id: If6e76206ae5bd8201c9928257706224f2f34c232
parent a20490cd
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -229,7 +229,8 @@ public class IconCache {
            Iterator<Entry<CacheKey, CacheEntry>> it = mCache.entrySet().iterator();
            while (it.hasNext()) {
                final CacheEntry e = it.next().getValue();
                if (e.icon.getWidth() < grid.iconSizePx || e.icon.getHeight() < grid.iconSizePx) {
                if ((e.icon != null) && (e.icon.getWidth() < grid.iconSizePx
                        || e.icon.getHeight() < grid.iconSizePx)) {
                    it.remove();
                }
            }