From 87326e0f88d7c2fcee3c96a3233e64cab7648779 Mon Sep 17 00:00:00 2001 From: Steven Moreland Date: Tue, 2 Feb 2021 02:18:56 +0000 Subject: [PATCH] NetworkRegistrationInfo: add Parcel recycle ~580 hits on cuttlefish boot Bug: 139327211 Test: boot w/ Parcel.java DEBUG_RECYCLE Change-Id: I20b7c8865c3ab1f562dfa9f19039f08cef8f0f7d --- telephony/java/android/telephony/NetworkRegistrationInfo.java | 1 + 1 file changed, 1 insertion(+) diff --git a/telephony/java/android/telephony/NetworkRegistrationInfo.java b/telephony/java/android/telephony/NetworkRegistrationInfo.java index 8507d8512a5cd..706e3cb93a0fc 100644 --- a/telephony/java/android/telephony/NetworkRegistrationInfo.java +++ b/telephony/java/android/telephony/NetworkRegistrationInfo.java @@ -344,6 +344,7 @@ public final class NetworkRegistrationInfo implements Parcelable { // TODO: Instead of doing this, we should create a formal way for cloning cell identity. // Cell identity is not an immutable object so we have to deep copy it. mCellIdentity = CellIdentity.CREATOR.createFromParcel(p); + p.recycle(); } if (nri.mVoiceSpecificInfo != null) {