diff options
author | Pacien TRAN-GIRARD | 2017-07-06 21:57:47 +0200 |
---|---|---|
committer | Pacien TRAN-GIRARD | 2017-07-06 22:02:12 +0200 |
commit | 29c989ad157e1b03b867c7a98158c32358df082f (patch) | |
tree | 737115688672ffeff31db3daeed1bfa82a804aa8 /app/src/main/java/org/pacien/tincapp/commands/Tinc.kt | |
parent | 819b3a44920e303a670928ee56e32b5ae02efca1 (diff) | |
download | tincapp-29c989ad157e1b03b867c7a98158c32358df082f.tar.gz |
Small cleanup
Diffstat (limited to 'app/src/main/java/org/pacien/tincapp/commands/Tinc.kt')
-rw-r--r-- | app/src/main/java/org/pacien/tincapp/commands/Tinc.kt | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/app/src/main/java/org/pacien/tincapp/commands/Tinc.kt b/app/src/main/java/org/pacien/tincapp/commands/Tinc.kt index e8ebb21..9b57233 100644 --- a/app/src/main/java/org/pacien/tincapp/commands/Tinc.kt +++ b/app/src/main/java/org/pacien/tincapp/commands/Tinc.kt | |||
@@ -13,17 +13,6 @@ object Tinc { | |||
13 | .withOption("config", AppPaths.confDir(netName).absolutePath) | 13 | .withOption("config", AppPaths.confDir(netName).absolutePath) |
14 | .withOption("pidfile", AppPaths.pidFile(netName).absolutePath) | 14 | .withOption("pidfile", AppPaths.pidFile(netName).absolutePath) |
15 | 15 | ||
16 | // independently runnable commands | ||
17 | |||
18 | @Throws(IOException::class) | ||
19 | fun fsck(netName: String, fix: Boolean): List<String> { | ||
20 | var cmd = newCommand(netName).withArguments("fsck") | ||
21 | if (fix) cmd = cmd.withOption("force") | ||
22 | return Executor.call(cmd) | ||
23 | } | ||
24 | |||
25 | // commands requiring a running tinc daemon | ||
26 | |||
27 | @Throws(IOException::class) | 16 | @Throws(IOException::class) |
28 | fun stop(netName: String) { | 17 | fun stop(netName: String) { |
29 | Executor.call(newCommand(netName).withArguments("stop")) | 18 | Executor.call(newCommand(netName).withArguments("stop")) |