Prefer IPv4 by default

"... in case of a single failure shows that for 86% of countries, IPv4 connectivity is more reliable."

https://blog.usejournal.com/national-internet-segments-reliability-survey-df8129b47743
pull/187/head
M66B 4 years ago
parent cfc19f33c8
commit 6f60234833

@ -1,7 +1,7 @@
apply plugin: 'com.android.application'
apply plugin: 'com.bugsnag.android.gradle'
def getVersionCode = { -> return 1377 }
def getVersionCode = { -> return 1378 }
def getReleaseName = { -> return "\"Ziapelta\"" }
// https://en.wikipedia.org/wiki/List_of_dinosaur_genera

@ -433,7 +433,7 @@ public class EmailService implements AutoCloseable {
main = InetAddress.getByName(host);
SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context);
boolean prefer_ip4 = prefs.getBoolean("prefer_ip4", false);
boolean prefer_ip4 = prefs.getBoolean("prefer_ip4", true);
if (prefer_ip4 && main instanceof Inet6Address) {
for (InetAddress iaddr : InetAddress.getAllByName(host))
if (iaddr instanceof Inet4Address) {

@ -280,7 +280,7 @@ public class FragmentOptionsConnection extends FragmentBase implements SharedPre
etTimeout.setText(timeout == 0 ? null : Integer.toString(timeout));
etTimeout.setHint(Integer.toString(EmailService.DEFAULT_CONNECT_TIMEOUT));
swPreferIp4.setChecked(prefs.getBoolean("prefer_ip4", false));
swPreferIp4.setChecked(prefs.getBoolean("prefer_ip4", true));
swSslHarden.setChecked(prefs.getBoolean("ssl_harden", false));
}

Loading…
Cancel
Save