am 6ce96faa: Don\'t mark an APN disabled if setup fails
Merge commit '6ce96faa0c8dc74ea6d1391aa54d9c6909810dc1' into eclair-plus-aosp * commit '6ce96faa0c8dc74ea6d1391aa54d9c6909810dc1': Don't mark an APN disabled if setup fails
This commit is contained in:
@@ -280,16 +280,8 @@ public abstract class DataConnectionTracker extends Handler {
|
||||
if (!dataEnabled[apnId]) {
|
||||
dataEnabled[apnId] = true;
|
||||
enabledCount++;
|
||||
if (enabledCount == 1) {
|
||||
if (onTrySetupData(null) == false) {
|
||||
// failed to setup data - note we can't optimize by only adj
|
||||
// these after a successfull call. dataEnabled must be set
|
||||
// prior or we think data is not available.
|
||||
dataEnabled[apnId] = false;
|
||||
enabledCount--;
|
||||
}
|
||||
}
|
||||
}
|
||||
onTrySetupData(null);
|
||||
} else {
|
||||
// disable
|
||||
if (dataEnabled[apnId]) {
|
||||
|
||||
@@ -568,8 +568,7 @@ public final class CdmaDataConnectionTracker extends DataConnectionTracker {
|
||||
private boolean retryAfterDisconnected(String reason) {
|
||||
boolean retry = true;
|
||||
|
||||
if ( Phone.REASON_RADIO_TURNED_OFF.equals(reason) ||
|
||||
Phone.REASON_DATA_DISABLED.equals(reason) ) {
|
||||
if ( Phone.REASON_RADIO_TURNED_OFF.equals(reason) ) {
|
||||
retry = false;
|
||||
}
|
||||
return retry;
|
||||
|
||||
@@ -1010,8 +1010,7 @@ public final class GsmDataConnectionTracker extends DataConnectionTracker {
|
||||
private boolean retryAfterDisconnected(String reason) {
|
||||
boolean retry = true;
|
||||
|
||||
if ( Phone.REASON_RADIO_TURNED_OFF.equals(reason) ||
|
||||
Phone.REASON_DATA_DISABLED.equals(reason) ) {
|
||||
if ( Phone.REASON_RADIO_TURNED_OFF.equals(reason) ) {
|
||||
retry = false;
|
||||
}
|
||||
return retry;
|
||||
|
||||
Reference in New Issue
Block a user