aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/tunnel/interfacewatcher.go
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2021-08-10 00:15:44 +0200
committerJason A. Donenfeld <Jason@zx2c4.com>2021-08-10 02:30:33 +0200
commit688876ff6361126b042b027e7f283f22f02e1a7e (patch)
tree8f3b7bdbe2812d2ad6da65570554d51260802787 /tunnel/interfacewatcher.go
parentembeddable-dll-service: csharp: update for wgnt (diff)
downloadwireguard-windows-688876ff6361126b042b027e7f283f22f02e1a7e.tar.xz
wireguard-windows-688876ff6361126b042b027e7f283f22f02e1a7e.zip
tunnel: provide better logging for when iphlpapi fails
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'tunnel/interfacewatcher.go')
-rw-r--r--tunnel/interfacewatcher.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/tunnel/interfacewatcher.go b/tunnel/interfacewatcher.go
index 32132e93..1abc021d 100644
--- a/tunnel/interfacewatcher.go
+++ b/tunnel/interfacewatcher.go
@@ -6,6 +6,7 @@
package tunnel
import (
+ "fmt"
"log"
"sync"
@@ -145,7 +146,7 @@ func watchInterface() (*interfaceWatcher, error) {
iw.setup(iface.Family)
})
if err != nil {
- return nil, err
+ return nil, fmt.Errorf("unable to register interface change callback: %w", err)
}
return iw, nil
}