Use the full SIM UICC to prevent possible collisions
Currently, Telephony registers the SIM PhoneAccounts using the partial
UICC, which has the possibility of colliding with another sim UICC on
a multi-SIM device. To Telecom, it looks like there is only one
PhoneAccount. We now register the full UICC with Telecom so that
this collision does not occur.
Change-Id: I517d05c69f1f2005b917f1e3463a14a235b49ad8
Fix: 25410213
diff --git a/src/com/android/phone/PhoneUtils.java b/src/com/android/phone/PhoneUtils.java
index aa62575..361c925 100644
--- a/src/com/android/phone/PhoneUtils.java
+++ b/src/com/android/phone/PhoneUtils.java
@@ -2412,7 +2412,7 @@
// TODO: Should use some sort of special hidden flag to decorate this account as
// an emergency-only account
String id = isEmergency ? EMERGENCY_ACCOUNT_HANDLE_ID : prefix +
- String.valueOf(phone.getIccSerialNumber());
+ String.valueOf(phone.getFullIccSerialNumber());
return makePstnPhoneAccountHandleWithPrefix(id, prefix, isEmergency);
}
@@ -2466,7 +2466,7 @@
private static Phone getPhoneFromIccId(String iccId) {
if (!TextUtils.isEmpty(iccId)) {
for (Phone phone : PhoneFactory.getPhones()) {
- String phoneIccId = phone.getIccSerialNumber();
+ String phoneIccId = phone.getFullIccSerialNumber();
if (iccId.equals(phoneIccId)) {
return phone;
}