The telephonyDisplayInfo is wrong after doing compatibility.

If one of the callers is do compatibility, then other caller get wrong
telephonyDisplayInfo.

Bug: 197521539
Test: Manually test at local and test the compatibility part and verify
the 5G+ icon.
Test: atest com.android.internal.telephony.TelephonyRegistryTest

Change-Id: Ic938f7623c802d04edc67678391cadc80c7dd084
This commit is contained in:
SongFerngWang
2021-09-09 01:29:41 +08:00
parent 766eff7df1
commit 5e9cca3afd

View File

@@ -1889,11 +1889,12 @@ public class TelephonyRegistry extends ITelephonyRegistry.Stub {
try {
if (!mConfigurationProvider.isDisplayInfoNrAdvancedSupported(
r.callingPackage, Binder.getCallingUserHandle())) {
telephonyDisplayInfo =
r.callback.onDisplayInfoChanged(
getBackwardCompatibleTelephonyDisplayInfo(
telephonyDisplayInfo);
telephonyDisplayInfo));
} else {
r.callback.onDisplayInfoChanged(telephonyDisplayInfo);
}
r.callback.onDisplayInfoChanged(telephonyDisplayInfo);
} catch (RemoteException ex) {
mRemoveList.add(r.binder);
}