Loading src/java/com/android/internal/telephony/SmsDispatchersController.java +14 −9 Original line number Diff line number Diff line Loading @@ -457,13 +457,18 @@ public class SmsDispatchersController extends Handler { } } private String getSmscAddressFromUSIM(String callingPkg) { private String getSmscAddressFromUSIMWithPhoneIdentity(String callingPkg) { final long identity = Binder.clearCallingIdentity(); try { IccSmsInterfaceManager iccSmsIntMgr = mPhone.getIccSmsInterfaceManager(); if (iccSmsIntMgr != null) { return iccSmsIntMgr.getSmscAddressFromIccEf(callingPkg); } else { Rlog.d(TAG, "getSmscAddressFromIccEf iccSmsIntMgr is null"); } } finally { Binder.restoreCallingIdentity(identity); } return null; } Loading Loading @@ -1300,7 +1305,7 @@ public class SmsDispatchersController extends Handler { protected void sendData(String callingPackage, String destAddr, String scAddr, int destPort, byte[] data, PendingIntent sentIntent, PendingIntent deliveryIntent, boolean isForVvm) { if (TextUtils.isEmpty(scAddr)) { scAddr = getSmscAddressFromUSIM(callingPackage); scAddr = getSmscAddressFromUSIMWithPhoneIdentity(callingPackage); } if (mDomainSelectionResolverProxy.isDomainSelectionSupported()) { Loading Loading @@ -1539,7 +1544,7 @@ public class SmsDispatchersController extends Handler { int priority, boolean expectMore, int validityPeriod, boolean isForVvm, long messageId, boolean skipShortCodeCheck) { if (TextUtils.isEmpty(scAddr)) { scAddr = getSmscAddressFromUSIM(callingPkg); scAddr = getSmscAddressFromUSIMWithPhoneIdentity(callingPkg); } if (mDomainSelectionResolverProxy.isDomainSelectionSupported()) { Loading Loading @@ -1688,7 +1693,7 @@ public class SmsDispatchersController extends Handler { boolean persistMessage, int priority, boolean expectMore, int validityPeriod, long messageId) { if (TextUtils.isEmpty(scAddr)) { scAddr = getSmscAddressFromUSIM(callingPkg); scAddr = getSmscAddressFromUSIMWithPhoneIdentity(callingPkg); } if (mDomainSelectionResolverProxy.isDomainSelectionSupported()) { Loading Loading
src/java/com/android/internal/telephony/SmsDispatchersController.java +14 −9 Original line number Diff line number Diff line Loading @@ -457,13 +457,18 @@ public class SmsDispatchersController extends Handler { } } private String getSmscAddressFromUSIM(String callingPkg) { private String getSmscAddressFromUSIMWithPhoneIdentity(String callingPkg) { final long identity = Binder.clearCallingIdentity(); try { IccSmsInterfaceManager iccSmsIntMgr = mPhone.getIccSmsInterfaceManager(); if (iccSmsIntMgr != null) { return iccSmsIntMgr.getSmscAddressFromIccEf(callingPkg); } else { Rlog.d(TAG, "getSmscAddressFromIccEf iccSmsIntMgr is null"); } } finally { Binder.restoreCallingIdentity(identity); } return null; } Loading Loading @@ -1300,7 +1305,7 @@ public class SmsDispatchersController extends Handler { protected void sendData(String callingPackage, String destAddr, String scAddr, int destPort, byte[] data, PendingIntent sentIntent, PendingIntent deliveryIntent, boolean isForVvm) { if (TextUtils.isEmpty(scAddr)) { scAddr = getSmscAddressFromUSIM(callingPackage); scAddr = getSmscAddressFromUSIMWithPhoneIdentity(callingPackage); } if (mDomainSelectionResolverProxy.isDomainSelectionSupported()) { Loading Loading @@ -1539,7 +1544,7 @@ public class SmsDispatchersController extends Handler { int priority, boolean expectMore, int validityPeriod, boolean isForVvm, long messageId, boolean skipShortCodeCheck) { if (TextUtils.isEmpty(scAddr)) { scAddr = getSmscAddressFromUSIM(callingPkg); scAddr = getSmscAddressFromUSIMWithPhoneIdentity(callingPkg); } if (mDomainSelectionResolverProxy.isDomainSelectionSupported()) { Loading Loading @@ -1688,7 +1693,7 @@ public class SmsDispatchersController extends Handler { boolean persistMessage, int priority, boolean expectMore, int validityPeriod, long messageId) { if (TextUtils.isEmpty(scAddr)) { scAddr = getSmscAddressFromUSIM(callingPkg); scAddr = getSmscAddressFromUSIMWithPhoneIdentity(callingPkg); } if (mDomainSelectionResolverProxy.isDomainSelectionSupported()) { Loading