Loading src/java/com/android/internal/telephony/ImsSmsDispatcher.java +114 −98 Original line number Diff line number Diff line Loading @@ -118,6 +118,8 @@ public class ImsSmsDispatcher extends SMSDispatcher { @Override public void onSendSmsResult(int token, int messageRef, @SendStatusResult int status, int reason, int networkReasonCode) { final long identity = Binder.clearCallingIdentity(); try { logd("onSendSmsResult token=" + token + " messageRef=" + messageRef + " status=" + status + " reason=" + reason + " networkReasonCode=" + networkReasonCode); Loading Loading @@ -152,11 +154,16 @@ public class ImsSmsDispatcher extends SMSDispatcher { break; default: } } finally { Binder.restoreCallingIdentity(identity); } } @Override public void onSmsStatusReportReceived(int token, String format, byte[] pdu) throws RemoteException { final long identity = Binder.clearCallingIdentity(); try { logd("Status report received."); android.telephony.SmsMessage message = android.telephony.SmsMessage.createFromPdu(pdu, format); Loading Loading @@ -195,10 +202,15 @@ public class ImsSmsDispatcher extends SMSDispatcher { if (result.second) { mTrackers.remove(key); } } finally { Binder.restoreCallingIdentity(identity); } } @Override public void onSmsReceived(int token, String format, byte[] pdu) { final long identity = Binder.clearCallingIdentity(); try { logd("SMS received."); android.telephony.SmsMessage message = android.telephony.SmsMessage.createFromPdu(pdu, format); Loading @@ -213,7 +225,8 @@ public class ImsSmsDispatcher extends SMSDispatcher { mappedResult = ImsSmsImplBase.DELIVER_STATUS_ERROR_NO_MEMORY; break; case Intents.RESULT_SMS_UNSUPPORTED: mappedResult = ImsSmsImplBase.DELIVER_STATUS_ERROR_REQUEST_NOT_SUPPORTED; mappedResult = ImsSmsImplBase.DELIVER_STATUS_ERROR_REQUEST_NOT_SUPPORTED; break; default: mappedResult = ImsSmsImplBase.DELIVER_STATUS_ERROR_GENERIC; Loading @@ -231,6 +244,9 @@ public class ImsSmsDispatcher extends SMSDispatcher { loge("Failed to acknowledgeSms(). Error: " + e.getMessage()); } }, true); } finally { Binder.restoreCallingIdentity(identity); } } }; Loading Loading
src/java/com/android/internal/telephony/ImsSmsDispatcher.java +114 −98 Original line number Diff line number Diff line Loading @@ -118,6 +118,8 @@ public class ImsSmsDispatcher extends SMSDispatcher { @Override public void onSendSmsResult(int token, int messageRef, @SendStatusResult int status, int reason, int networkReasonCode) { final long identity = Binder.clearCallingIdentity(); try { logd("onSendSmsResult token=" + token + " messageRef=" + messageRef + " status=" + status + " reason=" + reason + " networkReasonCode=" + networkReasonCode); Loading Loading @@ -152,11 +154,16 @@ public class ImsSmsDispatcher extends SMSDispatcher { break; default: } } finally { Binder.restoreCallingIdentity(identity); } } @Override public void onSmsStatusReportReceived(int token, String format, byte[] pdu) throws RemoteException { final long identity = Binder.clearCallingIdentity(); try { logd("Status report received."); android.telephony.SmsMessage message = android.telephony.SmsMessage.createFromPdu(pdu, format); Loading Loading @@ -195,10 +202,15 @@ public class ImsSmsDispatcher extends SMSDispatcher { if (result.second) { mTrackers.remove(key); } } finally { Binder.restoreCallingIdentity(identity); } } @Override public void onSmsReceived(int token, String format, byte[] pdu) { final long identity = Binder.clearCallingIdentity(); try { logd("SMS received."); android.telephony.SmsMessage message = android.telephony.SmsMessage.createFromPdu(pdu, format); Loading @@ -213,7 +225,8 @@ public class ImsSmsDispatcher extends SMSDispatcher { mappedResult = ImsSmsImplBase.DELIVER_STATUS_ERROR_NO_MEMORY; break; case Intents.RESULT_SMS_UNSUPPORTED: mappedResult = ImsSmsImplBase.DELIVER_STATUS_ERROR_REQUEST_NOT_SUPPORTED; mappedResult = ImsSmsImplBase.DELIVER_STATUS_ERROR_REQUEST_NOT_SUPPORTED; break; default: mappedResult = ImsSmsImplBase.DELIVER_STATUS_ERROR_GENERIC; Loading @@ -231,6 +244,9 @@ public class ImsSmsDispatcher extends SMSDispatcher { loge("Failed to acknowledgeSms(). Error: " + e.getMessage()); } }, true); } finally { Binder.restoreCallingIdentity(identity); } } }; Loading