summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorParménides GV <parmegv@sdf.org>2013-06-29 12:54:15 +0200
committerSean Leonard <meanderingcode@aetherislands.net>2013-07-12 14:27:04 -0600
commit3e04f2ab44e5e5e33efcfe515088ec3f918ccef0 (patch)
treea4105e2b59b7d1ff9615ff4583bc53c7b258b5c2
parent1ba2d488737bdb84847bbbc7cf9038610b1f094b (diff)
Distinguish non LEAP provider and down provider.
I've set ProviderAPI to show its own toast depending on the exception that getStringFromProvider issues. If the socket timeout reaches its end, a toast different from when an IOException or a MalformedException occur.
-rwxr-xr-xres/values/strings.xml1
-rw-r--r--src/se/leap/leapclient/ProviderAPI.java1
2 files changed, 2 insertions, 0 deletions
diff --git a/res/values/strings.xml b/res/values/strings.xml
index c7ef6c2b..c8f391ad 100755
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -306,6 +306,7 @@
<string name="authenticating_message">Authenticating with entered login and password.</string>
<string name="logout_title">Log out</string>
<string name="logout_message">Logging out from this session.</string>
+ <string name="not_valid_password_message">Your password is not well-formed: it should have at least 8 characters.</string>
<string name="succesful_authentication_message">Authentication succeeded.</string>
<string name="authentication_failed_message">Authentication failed.</string>
<string name="successful_log_out_message">Logged out.</string>
diff --git a/src/se/leap/leapclient/ProviderAPI.java b/src/se/leap/leapclient/ProviderAPI.java
index 5238224e..fba0ab01 100644
--- a/src/se/leap/leapclient/ProviderAPI.java
+++ b/src/se/leap/leapclient/ProviderAPI.java
@@ -396,6 +396,7 @@ public class ProviderAPI extends IntentService {
} else {
displayToast(R.string.certificate_error);
}
+ displayToast(R.string.malformed_url);
} catch (Exception e) {
if(provider_url != null && danger_on) {
json_file_content = getStringFromProviderWithoutValidate(provider_url);