aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/service
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2019-03-01 05:19:34 +0100
committerJason A. Donenfeld <Jason@zx2c4.com>2019-03-01 05:20:03 +0100
commitf10fe084016ad9756e319e1cf607a3ec07f5f9a9 (patch)
treebe521a2b6d696f7efdb544e34f651ab139647bcf /service
parenttunnel: write panic log to eventlog (diff)
downloadwireguard-windows-f10fe084016ad9756e319e1cf607a3ec07f5f9a9.tar.xz
wireguard-windows-f10fe084016ad9756e319e1cf607a3ec07f5f9a9.zip
tunnel: set dns
Diffstat (limited to 'service')
-rw-r--r--service/service_tunnel.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/service/service_tunnel.go b/service/service_tunnel.go
index 7ff8c0ff..5dae5d50 100644
--- a/service/service_tunnel.go
+++ b/service/service_tunnel.go
@@ -239,8 +239,11 @@ func (service *tunnelService) Execute(args []string, r <-chan svc.ChangeRequest,
}
}
}
+ if err == nil {
+ err = iface.SetDNS(conf.Interface.Dns)
+ }
if err != nil {
- logger.Error.Println("Unable to set interface addresses and routes:", err)
+ logger.Error.Println("Unable to set interface addresses, routes, or DNSes:", err)
changes <- svc.Status{State: svc.StopPending}
exitCode = ERROR_NETWORK_BUSY
device.Close()