summaryrefslogtreecommitdiff
path: root/src/de/blinkt/openvpn/ProfileManager.java
diff options
context:
space:
mode:
authorArne Schwabe <arne@rfc2549.org>2012-05-14 19:34:03 +0200
committerArne Schwabe <arne@rfc2549.org>2012-05-14 19:34:03 +0200
commit7a36968fa5d065236edfa1f74dea50e1e1595998 (patch)
treed69f4b724d570f87eca4d12c716302777da4805e /src/de/blinkt/openvpn/ProfileManager.java
parent1f490292a90ab16c24231fc3965771387bbbed05 (diff)
Add more error logging
Diffstat (limited to 'src/de/blinkt/openvpn/ProfileManager.java')
-rw-r--r--src/de/blinkt/openvpn/ProfileManager.java15
1 files changed, 11 insertions, 4 deletions
diff --git a/src/de/blinkt/openvpn/ProfileManager.java b/src/de/blinkt/openvpn/ProfileManager.java
index f8193003..d34bdbec 100644
--- a/src/de/blinkt/openvpn/ProfileManager.java
+++ b/src/de/blinkt/openvpn/ProfileManager.java
@@ -87,9 +87,12 @@ public class ProfileManager {
} catch (FileNotFoundException e) {
e.printStackTrace();
+ throw new RuntimeException(e);
} catch (IOException e) {
e.printStackTrace();
+ throw new RuntimeException(e);
+
}
}
@@ -98,6 +101,7 @@ public class ProfileManager {
profiles = new HashMap<String, VpnProfile>();
SharedPreferences settings =context.getSharedPreferences(PREFS_NAME,Activity.MODE_PRIVATE);
Set<String> vlist = settings.getStringSet("vpnlist", null);
+ Exception exp =null;
if(vlist==null){
vlist = new HashSet<String>();
}
@@ -110,13 +114,16 @@ public class ProfileManager {
profiles.put(vp.getUUID().toString(), vp);
} catch (StreamCorruptedException e) {
- e.printStackTrace();
+ exp=e;
} catch (FileNotFoundException e) {
- e.printStackTrace();
+ exp=e;
} catch (IOException e) {
- e.printStackTrace();
+ exp=e;
} catch (ClassNotFoundException e) {
- e.printStackTrace();
+ exp=e;
+ }
+ if(exp!=null) {
+ exp.printStackTrace();
}
}
}