summaryrefslogtreecommitdiff
path: root/main
diff options
context:
space:
mode:
authorArne Schwabe <arne@rfc2549.org>2016-06-16 11:00:58 +0200
committerArne Schwabe <arne@rfc2549.org>2016-06-16 11:01:06 +0200
commit475a466d5c32f65b89c9124c8b5b163707a13d6e (patch)
treefb3438f62323b052d23b779798947604bf175728 /main
parentb916d36bc7bb4d1efbf227ce86862519b5bde6e5 (diff)
Fix mtu option doing nothing with default settings.
Diffstat (limited to 'main')
-rw-r--r--main/src/main/java/de/blinkt/openvpn/VpnProfile.java2
-rw-r--r--main/src/main/java/de/blinkt/openvpn/core/ConfigParser.java2
-rw-r--r--main/src/main/java/de/blinkt/openvpn/fragments/Settings_IP.java4
3 files changed, 5 insertions, 3 deletions
diff --git a/main/src/main/java/de/blinkt/openvpn/VpnProfile.java b/main/src/main/java/de/blinkt/openvpn/VpnProfile.java
index 31a52ec0..505406a9 100644
--- a/main/src/main/java/de/blinkt/openvpn/VpnProfile.java
+++ b/main/src/main/java/de/blinkt/openvpn/VpnProfile.java
@@ -71,7 +71,7 @@ public class VpnProfile implements Serializable, Cloneable {
private static final long serialVersionUID = 7085688938959334563L;
public static final int MAXLOGLEVEL = 4;
public static final int CURRENT_PROFILE_VERSION = 6;
- public static final int DEFAULT_MSSFIX_SIZE = 1450;
+ public static final int DEFAULT_MSSFIX_SIZE = 1280;
public static String DEFAULT_DNS1 = "8.8.8.8";
public static String DEFAULT_DNS2 = "8.8.4.4";
diff --git a/main/src/main/java/de/blinkt/openvpn/core/ConfigParser.java b/main/src/main/java/de/blinkt/openvpn/core/ConfigParser.java
index 57635cf4..38161055 100644
--- a/main/src/main/java/de/blinkt/openvpn/core/ConfigParser.java
+++ b/main/src/main/java/de/blinkt/openvpn/core/ConfigParser.java
@@ -448,7 +448,7 @@ public class ConfigParser {
throw new ConfigParseError("Argument to --mssfix has to be an integer");
}
} else {
- np.mMssFix = VpnProfile.DEFAULT_MSSFIX_SIZE;
+ np.mMssFix = 1450; // OpenVPN default size
}
}
diff --git a/main/src/main/java/de/blinkt/openvpn/fragments/Settings_IP.java b/main/src/main/java/de/blinkt/openvpn/fragments/Settings_IP.java
index 7ce6dd1c..44f01296 100644
--- a/main/src/main/java/de/blinkt/openvpn/fragments/Settings_IP.java
+++ b/main/src/main/java/de/blinkt/openvpn/fragments/Settings_IP.java
@@ -59,7 +59,7 @@ public class Settings_IP extends OpenVpnPreferencesFragment implements OnPrefere
@Override
protected void loadSettings() {
-
+
mUsePull.setChecked(mProfile.mUsePull);
mIPv4.setText(mProfile.mIPv4Address);
mIPv6.setText(mProfile.mIPv6Address);
@@ -71,6 +71,8 @@ public class Settings_IP extends OpenVpnPreferencesFragment implements OnPrefere
if (mProfile.mAuthenticationType == VpnProfile.TYPE_STATICKEYS)
mUsePull.setChecked(false);
+ mUsePull.setEnabled(mProfile.mAuthenticationType == VpnProfile.TYPE_STATICKEYS);
+
// Sets Summary
onPreferenceChange(mIPv4, mIPv4.getText());
onPreferenceChange(mIPv6, mIPv6.getText());