From 5de2f89c7880afaf457749211e445bfffb6d3b7b Mon Sep 17 00:00:00 2001 From: Ling Ma Date: Wed, 5 Mar 2025 13:32:31 -0800 Subject: [log] debug getDataNetworkType Fix: 400506639 Test: basic voice call Flag: EXEMPT log only Change-Id: I40d40c4904770c9ad8bb8f49d33163a48501f9e3 --- telephony/java/android/telephony/TelephonyManager.java | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'telephony') diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java index 41569deeddb5..9364f646d54b 100644 --- a/telephony/java/android/telephony/TelephonyManager.java +++ b/telephony/java/android/telephony/TelephonyManager.java @@ -3374,14 +3374,13 @@ public class TelephonyManager { return telephony.getDataNetworkTypeForSubscriber(subId, getOpPackageName(), getAttributionTag()); } else { - // This can happen when the ITelephony interface is not up yet. + Log.e(TAG, "getDataNetworkType: ITelephony interface is not up yet"); return NETWORK_TYPE_UNKNOWN; } - } catch(RemoteException ex) { - // This shouldn't happen in the normal case - return NETWORK_TYPE_UNKNOWN; - } catch (NullPointerException ex) { - // This could happen before phone restarts due to crashing + } catch (RemoteException // Shouldn't happen in the normal case + | NullPointerException ex // Could happen before phone restarts due to crashing + ) { + Log.e(TAG, "getDataNetworkType: " + ex.getMessage()); return NETWORK_TYPE_UNKNOWN; } } -- cgit v1.2.3-59-g8ed1b