summaryrefslogtreecommitdiffstats
path: root/vpn/java
diff options
context:
space:
mode:
authorHung-ying Tyan <tyanh@google.com>2009-08-03 16:22:24 +0800
committerHung-ying Tyan <tyanh@google.com>2009-08-03 16:22:24 +0800
commit935406709edb9aaf6538e23e88ecfdf77cccd8ba (patch)
tree14dd901184665435a1529013b0581fdc2b0c4ddd /vpn/java
parentdc1d5704a725d207b98de1b117847297958d9148 (diff)
downloadframeworks_base-935406709edb9aaf6538e23e88ecfdf77cccd8ba.zip
frameworks_base-935406709edb9aaf6538e23e88ecfdf77cccd8ba.tar.gz
frameworks_base-935406709edb9aaf6538e23e88ecfdf77cccd8ba.tar.bz2
Issue an error when VPN connection is lost.
+ Add new error code CONNECTION_LOST to VpnManager. + Make VpnService call onError() instead of onDisconnect() when connection is lost. + Make VpnService broadcast CONNECTION_LOST when that happens.
Diffstat (limited to 'vpn/java')
-rw-r--r--vpn/java/android/net/vpn/VpnManager.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/vpn/java/android/net/vpn/VpnManager.java b/vpn/java/android/net/vpn/VpnManager.java
index e448e5a..f71bbea 100644
--- a/vpn/java/android/net/vpn/VpnManager.java
+++ b/vpn/java/android/net/vpn/VpnManager.java
@@ -54,6 +54,8 @@ public class VpnManager {
public static final int VPN_ERROR_CHALLENGE = 4;
/** Error code to indicate an error of remote server hanging up. */
public static final int VPN_ERROR_REMOTE_HUNG_UP = 5;
+ /** Error code to indicate an error of losing connectivity. */
+ public static final int VPN_ERROR_CONNECTION_LOST = 6;
private static final int VPN_ERROR_NO_ERROR = 0;
public static final String PROFILES_PATH = "/data/misc/vpn/profiles";