summaryrefslogtreecommitdiffstats
path: root/core/java
diff options
context:
space:
mode:
Diffstat (limited to 'core/java')
-rw-r--r--core/java/android/os/Bundle.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/core/java/android/os/Bundle.java b/core/java/android/os/Bundle.java
index 2b0ae3a..48eb8cc 100644
--- a/core/java/android/os/Bundle.java
+++ b/core/java/android/os/Bundle.java
@@ -216,6 +216,8 @@ public final class Bundle implements Parcelable, Cloneable {
}
if (mMap == null) {
mMap = new ArrayMap<String, Object>(N);
+ } else {
+ mMap.ensureCapacity(N);
}
mParcelledData.readArrayMapInternal(mMap, N, mClassLoader);
mParcelledData.recycle();