aboutsummaryrefslogtreecommitdiff
path: root/src/manager/mod.rs
diff options
context:
space:
mode:
authorHristo Venev <hristo@venev.name>2020-02-04 20:31:51 +0100
committerHristo Venev <hristo@venev.name>2020-02-04 20:31:51 +0100
commitc4f743e2a33ba39036f7e9919b7adc80415b1754 (patch)
treec708bbc6e089a1b66c61d189a010cb2a80aa0a34 /src/manager/mod.rs
parent3f5c00af303c1b706a74cafa58ff23b068f6d819 (diff)
Reference preshared keys by path.
Diffstat (limited to 'src/manager/mod.rs')
-rw-r--r--src/manager/mod.rs6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/manager/mod.rs b/src/manager/mod.rs
index 8df4d23..b7fb8c2 100644
--- a/src/manager/mod.rs
+++ b/src/manager/mod.rs
@@ -35,10 +35,12 @@ impl Manager {
let runtime_directory = c.runtime_directory.ok_or_else(|| {
io::Error::new(io::ErrorKind::InvalidInput, "runtime directory required")
})?;
- let mut state_path = runtime_directory.clone();
+
+ let mut state_path = runtime_directory;
state_path.push("state.json");
+
let mut m = Self {
- dev: wg::Device::open(ifname, runtime_directory)?,
+ dev: wg::Device::open(ifname)?,
global_config: c.global,
sources: vec![],
current: model::Config::empty(),