From 2785def37a8d64906b9d4e2c213c7d387cfb18af Mon Sep 17 00:00:00 2001 From: "Jason A. Donenfeld" Date: Tue, 9 Jan 2018 12:21:01 +0100 Subject: [PATCH] RootShell: synchronize accesses to single shell Signed-off-by: Jason A. Donenfeld --- app/src/main/java/com/wireguard/android/util/RootShell.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/com/wireguard/android/util/RootShell.java b/app/src/main/java/com/wireguard/android/util/RootShell.java index 947a6679..f8b5bb9f 100644 --- a/app/src/main/java/com/wireguard/android/util/RootShell.java +++ b/app/src/main/java/com/wireguard/android/util/RootShell.java @@ -127,7 +127,7 @@ public class RootShell { * @param command Command to run as root. * @return The exit value of the last command run, or -1 if there was an internal error. */ - public int run(final Collection output, final String command) + public synchronized int run(final Collection output, final String command) throws ErrnoException, IOException, NoRootException { ensureRoot();