summaryrefslogtreecommitdiffhomepage
path: root/app/src/main/java/com/wireguard/android/backend
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2018-05-29 05:07:50 +0200
committerJason A. Donenfeld <Jason@zx2c4.com>2018-05-29 05:09:37 +0200
commitded0191aae5bfe14409f343c0e3ce3b5db47261a (patch)
tree126cc6f78fc65970f9359ba1015d99e7a098efbc /app/src/main/java/com/wireguard/android/backend
parent9245e9536ac0e20f03049f074a6a3934447b3d35 (diff)
SharedLibraryLoader: introduce to work around Samsung PackageManager bugs
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'app/src/main/java/com/wireguard/android/backend')
-rw-r--r--app/src/main/java/com/wireguard/android/backend/GoBackend.java6
1 files changed, 2 insertions, 4 deletions
diff --git a/app/src/main/java/com/wireguard/android/backend/GoBackend.java b/app/src/main/java/com/wireguard/android/backend/GoBackend.java
index ffd05eae..4963f759 100644
--- a/app/src/main/java/com/wireguard/android/backend/GoBackend.java
+++ b/app/src/main/java/com/wireguard/android/backend/GoBackend.java
@@ -19,6 +19,7 @@ import com.wireguard.android.model.Tunnel;
import com.wireguard.android.model.Tunnel.State;
import com.wireguard.android.model.Tunnel.Statistics;
import com.wireguard.android.util.ExceptionLoggers;
+import com.wireguard.android.util.SharedLibraryLoader;
import com.wireguard.config.Config;
import com.wireguard.config.IPCidr;
import com.wireguard.config.Interface;
@@ -38,15 +39,12 @@ public final class GoBackend implements Backend {
private static final String TAG = "WireGuard/" + GoBackend.class.getSimpleName();
private static CompletableFuture<VpnService> vpnService = new CompletableFuture<>();
- static {
- System.loadLibrary("wg-go");
- }
-
private final Context context;
private Tunnel currentTunnel;
private int currentTunnelHandle = -1;
public GoBackend(final Context context) {
+ SharedLibraryLoader.loadSharedLibrary(context, "wg-go");
this.context = context;
}