Merge "Correctly serialize population" into sc-dev am: ba23b84687 am: 6271ec4e51

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

Change-Id: Ie174bb0eab45c8ff616d2e214dd11dc08ff65eae
This commit is contained in:
Lucas Dupin
2021-06-23 19:06:06 +00:00
committed by Automerger Merge Worker

View File

@@ -420,7 +420,7 @@ public final class WallpaperColors implements Parcelable {
for (Map.Entry<Integer, Integer> colorEntry : mAllColors.entrySet()) {
if (colorEntry.getKey() != null) {
dest.writeInt(colorEntry.getKey());
Integer population = mAllColors.get(colorEntry.getValue());
Integer population = colorEntry.getValue();
int populationInt = (population != null) ? population : 0;
dest.writeInt(populationInt);
}