diff options
Diffstat (limited to 'app/src/main/java/de')
-rw-r--r-- | app/src/main/java/de/blinkt/openvpn/core/ConfigParser.java | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/app/src/main/java/de/blinkt/openvpn/core/ConfigParser.java b/app/src/main/java/de/blinkt/openvpn/core/ConfigParser.java index 10dd7033..6063ea53 100644 --- a/app/src/main/java/de/blinkt/openvpn/core/ConfigParser.java +++ b/app/src/main/java/de/blinkt/openvpn/core/ConfigParser.java @@ -5,10 +5,13 @@ package de.blinkt.openvpn.core; +import static de.blinkt.openvpn.core.connection.Connection.TransportType.PT; + import android.os.Build; -import androidx.core.util.Pair; import android.text.TextUtils; +import androidx.core.util.Pair; + import java.io.BufferedReader; import java.io.IOException; import java.io.Reader; @@ -27,8 +30,6 @@ import de.blinkt.openvpn.core.connection.Obfs4Connection; import de.blinkt.openvpn.core.connection.OpenvpnConnection; import se.leap.bitmaskclient.pluggableTransports.Obfs4Options; -import static de.blinkt.openvpn.core.connection.Connection.TransportType.OBFS4; - //! Openvpn Config FIle Parser, probably not 100% accurate but close enough // And remember, this is valid :) @@ -807,7 +808,7 @@ public class ConfigParser { return null; } else - conn = transportType == OBFS4 ? new Obfs4Connection(obfs4Options) : new OpenvpnConnection(); + conn = transportType.getMetaType() == PT ? new Obfs4Connection(obfs4Options) : new OpenvpnConnection(); Vector<String> port = getOption("port", 1, 1); if (port != null) { |