summaryrefslogtreecommitdiff
path: root/src/com/android/mms/transaction/TransactionService.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/com/android/mms/transaction/TransactionService.java')
-rw-r--r--src/com/android/mms/transaction/TransactionService.java11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/com/android/mms/transaction/TransactionService.java b/src/com/android/mms/transaction/TransactionService.java
index 3d26e7b4..4eac8480 100644
--- a/src/com/android/mms/transaction/TransactionService.java
+++ b/src/com/android/mms/transaction/TransactionService.java
@@ -207,7 +207,7 @@ public class TransactionService extends Service implements Observer {
public void onNewIntent(Intent intent, int serviceId) {
mConnMgr = (ConnectivityManager) getSystemService(Context.CONNECTIVITY_SERVICE);
if (mConnMgr == null || !SubStatusResolver.isMobileDataEnabledOnAnySub(getApplicationContext())
- || !MmsConfig.isSmsEnabled(getApplicationContext())) {
+ || !MmsConfig.isSmsEnabled()) {
endMmsConnectivity(mMmsDatasubId);
stopSelf(serviceId);
return;
@@ -971,13 +971,16 @@ public class TransactionService extends Service implements Observer {
public void onReceive(Context context, Intent intent) {
String action = intent.getAction();
int subId = intent.getIntExtra(PhoneConstants.SUBSCRIPTION_KEY,
- SubscriptionManager.INVALID_SUB_ID);
+ SubscriptionManager.getDefaultSmsSubId());
if (Log.isLoggable(LogTag.TRANSACTION, Log.VERBOSE)) {
- Log.w(TAG, "ConnectivityBroadcastReceiver.onReceive() action: " + action);
+ Log.w(TAG, "ConnectivityBroadcastReceiver.onReceive() action: " + action +
+ " subId: " + subId);
}
-
if (!action.equals(ConnectivityManager.CONNECTIVITY_ACTION)
|| !SubscriptionManager.isValidSubId(subId)) {
+ if (Log.isLoggable(LogTag.TRANSACTION, Log.VERBOSE)) {
+ Log.v(TAG, "onReceive: bailing because of non-valid subId: " + subId);
+ }
return;
}