Loading services/core/java/com/android/server/connectivity/Tethering.java +8 −9 Original line number Original line Diff line number Diff line Loading @@ -1538,9 +1538,8 @@ public class Tethering extends BaseNetworkObserver implements IControlsTethering // used to verify this receiver is still current // used to verify this receiver is still current final private int mGenerationNumber; final private int mGenerationNumber; // we're interested in edge-triggered LOADED notifications, so // used to check the sim state transition from non-loaded to loaded // ignore LOADED unless we saw an ABSENT state first private boolean mSimNotLoadedSeen = false; private boolean mSimAbsentSeen = false; public SimChangeBroadcastReceiver(int generationNumber) { public SimChangeBroadcastReceiver(int generationNumber) { super(); super(); Loading @@ -1558,14 +1557,14 @@ public class Tethering extends BaseNetworkObserver implements IControlsTethering final String state = final String state = intent.getStringExtra(IccCardConstants.INTENT_KEY_ICC_STATE); intent.getStringExtra(IccCardConstants.INTENT_KEY_ICC_STATE); Log.d(TAG, "got Sim changed to state " + state + ", mSimAbsentSeen=" + Log.d(TAG, "got Sim changed to state " + state + ", mSimNotLoadedSeen=" + mSimAbsentSeen); mSimNotLoadedSeen); if (!mSimAbsentSeen && IccCardConstants.INTENT_VALUE_ICC_ABSENT.equals(state)) { if (!mSimNotLoadedSeen && !IccCardConstants.INTENT_VALUE_ICC_LOADED.equals(state)) { mSimAbsentSeen = true; mSimNotLoadedSeen = true; } } if (mSimAbsentSeen && IccCardConstants.INTENT_VALUE_ICC_LOADED.equals(state)) { if (mSimNotLoadedSeen && IccCardConstants.INTENT_VALUE_ICC_LOADED.equals(state)) { mSimAbsentSeen = false; mSimNotLoadedSeen = false; try { try { if (mContext.getResources().getString(com.android.internal.R.string. if (mContext.getResources().getString(com.android.internal.R.string. config_mobile_hotspot_provision_app_no_ui).isEmpty() == false) { config_mobile_hotspot_provision_app_no_ui).isEmpty() == false) { Loading Loading
services/core/java/com/android/server/connectivity/Tethering.java +8 −9 Original line number Original line Diff line number Diff line Loading @@ -1538,9 +1538,8 @@ public class Tethering extends BaseNetworkObserver implements IControlsTethering // used to verify this receiver is still current // used to verify this receiver is still current final private int mGenerationNumber; final private int mGenerationNumber; // we're interested in edge-triggered LOADED notifications, so // used to check the sim state transition from non-loaded to loaded // ignore LOADED unless we saw an ABSENT state first private boolean mSimNotLoadedSeen = false; private boolean mSimAbsentSeen = false; public SimChangeBroadcastReceiver(int generationNumber) { public SimChangeBroadcastReceiver(int generationNumber) { super(); super(); Loading @@ -1558,14 +1557,14 @@ public class Tethering extends BaseNetworkObserver implements IControlsTethering final String state = final String state = intent.getStringExtra(IccCardConstants.INTENT_KEY_ICC_STATE); intent.getStringExtra(IccCardConstants.INTENT_KEY_ICC_STATE); Log.d(TAG, "got Sim changed to state " + state + ", mSimAbsentSeen=" + Log.d(TAG, "got Sim changed to state " + state + ", mSimNotLoadedSeen=" + mSimAbsentSeen); mSimNotLoadedSeen); if (!mSimAbsentSeen && IccCardConstants.INTENT_VALUE_ICC_ABSENT.equals(state)) { if (!mSimNotLoadedSeen && !IccCardConstants.INTENT_VALUE_ICC_LOADED.equals(state)) { mSimAbsentSeen = true; mSimNotLoadedSeen = true; } } if (mSimAbsentSeen && IccCardConstants.INTENT_VALUE_ICC_LOADED.equals(state)) { if (mSimNotLoadedSeen && IccCardConstants.INTENT_VALUE_ICC_LOADED.equals(state)) { mSimAbsentSeen = false; mSimNotLoadedSeen = false; try { try { if (mContext.getResources().getString(com.android.internal.R.string. if (mContext.getResources().getString(com.android.internal.R.string. config_mobile_hotspot_provision_app_no_ui).isEmpty() == false) { config_mobile_hotspot_provision_app_no_ui).isEmpty() == false) { Loading