diff options
| author | Mikael Hedegren <mikael.hedegren@sonyericsson.com> | 2012-12-14 15:52:52 +0100 |
|---|---|---|
| committer | Zoran Jovanovic <zoran.jovanovic@sonymobile.com> | 2012-12-18 15:32:48 +0100 |
| commit | 342a7cb69f8e0cfe208b12cc451c445ae8583e04 (patch) | |
| tree | c32f4e5ddee2db228289d2f18f11594c62e078cb /services/java/com/android/server/ConnectivityService.java | |
| parent | 568f923ba4cf522f699837bee0d8cba318343345 (diff) | |
Return error upon attempt to use non-existent APN
startUsingNetworkFeature will ignore errors from
reconnect - causing ConnectivityService to send
faulty information back to requester.
Change-Id: I4e0fcc1addd84da409cdc1eed1a95d25d925e020
Diffstat (limited to 'services/java/com/android/server/ConnectivityService.java')
| -rw-r--r-- | services/java/com/android/server/ConnectivityService.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/services/java/com/android/server/ConnectivityService.java b/services/java/com/android/server/ConnectivityService.java index ad1dfb279961..ec682e8e33f1 100644 --- a/services/java/com/android/server/ConnectivityService.java +++ b/services/java/com/android/server/ConnectivityService.java @@ -1183,8 +1183,11 @@ public class ConnectivityService extends IConnectivityManager.Stub { log("startUsingNetworkFeature reconnecting to " + networkType + ": " + feature); } - network.reconnect(); - return PhoneConstants.APN_REQUEST_STARTED; + if (network.reconnect()) { + return PhoneConstants.APN_REQUEST_STARTED; + } else { + return PhoneConstants.APN_REQUEST_FAILED; + } } else { // need to remember this unsupported request so we respond appropriately on stop synchronized(this) { |
