summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorLinus Färnstrand <linus@mullvad.net>2018-12-12 11:46:02 +0100
committerLinus Färnstrand <linus@mullvad.net>2018-12-12 11:46:02 +0100
commit893b15bfb5bf5d588ee7c0f6d98bcffe7d67ab96 (patch)
treea9c33b3d569d2aa8ffb1c823e743a82ea02c8383
parent19ed1e0b08de9f32715dfa7f9591fd90922be8e4 (diff)
downloadmullvadvpn-893b15bfb5bf5d588ee7c0f6d98bcffe7d67ab96.tar.xz
mullvadvpn-893b15bfb5bf5d588ee7c0f6d98bcffe7d67ab96.zip
Capture and log stderr from resolvconf when failing
-rw-r--r--talpid-core/src/security/linux/dns/resolvconf.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/talpid-core/src/security/linux/dns/resolvconf.rs b/talpid-core/src/security/linux/dns/resolvconf.rs
index 7d3f1162db..5c844c3355 100644
--- a/talpid-core/src/security/linux/dns/resolvconf.rs
+++ b/talpid-core/src/security/linux/dns/resolvconf.rs
@@ -47,6 +47,8 @@ impl Resolvconf {
let output = duct::cmd!(&self.resolvconf, "-a", &record_name)
.input(record_contents)
+ .stderr_capture()
+ .unchecked()
.run()
.chain_err(|| ErrorKind::RunResolvconf)?;
@@ -65,6 +67,8 @@ impl Resolvconf {
for record_name in self.record_names.drain() {
let output = duct::cmd!(&self.resolvconf, "-d", &record_name)
+ .stderr_capture()
+ .unchecked()
.run()
.chain_err(|| ErrorKind::RunResolvconf)?;