summaryrefslogtreecommitdiff
path: root/src/de/blinkt/openvpn/OpenVPN.java
diff options
context:
space:
mode:
authorArne Schwabe <arne@rfc2549.org>2012-05-06 23:52:22 +0200
committerArne Schwabe <arne@rfc2549.org>2012-05-06 23:52:22 +0200
commitef42511eb479c40dc205e21c70e0871f35490e72 (patch)
tree48c8f08d3f2ce778a28f17f0abd25f5c75d67814 /src/de/blinkt/openvpn/OpenVPN.java
parent49c3df575626efefe85b2fe14cad2dac6509d10d (diff)
All control of openvpn is now over the unix socket. JNI is only used for starting openvpn.
Fix configuration if no DNS information is available. (closes issue #7 hopefully) Version 0.5.0
Diffstat (limited to 'src/de/blinkt/openvpn/OpenVPN.java')
-rw-r--r--src/de/blinkt/openvpn/OpenVPN.java16
1 files changed, 3 insertions, 13 deletions
diff --git a/src/de/blinkt/openvpn/OpenVPN.java b/src/de/blinkt/openvpn/OpenVPN.java
index cc827aae..e524da1c 100644
--- a/src/de/blinkt/openvpn/OpenVPN.java
+++ b/src/de/blinkt/openvpn/OpenVPN.java
@@ -8,7 +8,6 @@ import android.util.Log;
public class OpenVPN {
private static OpenVpnService mOpenVpnService;
private static final int MAXLOGENTRIES = 500;
- public static native int startOpenVPNThread();
public static native int startOpenVPNThreadArgs(String argv[]);
private static final String TAG = "OpenVpn";
@@ -30,14 +29,9 @@ public class OpenVPN {
System.loadLibrary("openvpn");
}
- static void addRoute(String dest,String mask, String gw) {
- Log.i("openvpn" ,"Got Routing information " + dest + " " + mask + " " + gw );
- mOpenVpnService.addRoute(dest,mask);
- }
-
synchronized static void logMessage(int level,String prefix, String message)
{
- logbuffer.addLast(prefix + " " + message);
+ logbuffer.addLast(prefix + message);
if(logbuffer.size()>MAXLOGENTRIES)
logbuffer.removeFirst();
@@ -49,7 +43,7 @@ public class OpenVPN {
}
for (LogListener ll : logListener) {
- ll.newLog(prefix + " " + message);
+ ll.newLog(prefix + message);
}
}
@@ -72,11 +66,7 @@ public class OpenVPN {
public static void setCallback(OpenVpnService openVpnService) {
mOpenVpnService = openVpnService;
}
-
- public static int openTunDevice() {
- Log.d(TAG,"Opening tun device");
- return mOpenVpnService.openTun();
- }
+
//! Dummy method being called to force loading of JNI Libraries
public static void foo() { }