diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2019-05-25 02:23:34 +0200 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2019-05-25 02:23:34 +0200 |
commit | 8dbf1db58a17542f3d9bc2d25efa70b783314c54 (patch) | |
tree | 432899e15da424b1a2c28041190db3144c94480c /tunnel | |
parent | build: opt in to walk cgo (diff) | |
download | wireguard-windows-8dbf1db58a17542f3d9bc2d25efa70b783314c54.tar.xz wireguard-windows-8dbf1db58a17542f3d9bc2d25efa70b783314c54.zip |
global: use filepath.Join uniformly
Diffstat (limited to 'tunnel')
-rw-r--r-- | tunnel/winipcfg/netsh.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tunnel/winipcfg/netsh.go b/tunnel/winipcfg/netsh.go index 4cff5de8..4714c520 100644 --- a/tunnel/winipcfg/netsh.go +++ b/tunnel/winipcfg/netsh.go @@ -10,6 +10,7 @@ import ( "fmt" "io" "os/exec" + "path/filepath" "strings" "golang.org/x/sys/windows" @@ -23,7 +24,7 @@ func runNetsh(cmds []string) error { if err != nil { return err } - cmd := exec.Command(system32 + "\\netsh.exe") // I wish we could append (, "-f", "CONIN$") but Go sets up the process context wrong. + cmd := exec.Command(filepath.Join(system32, "netsh.exe")) // I wish we could append (, "-f", "CONIN$") but Go sets up the process context wrong. stdin, err := cmd.StdinPipe() if err != nil { return fmt.Errorf("runNetsh stdin pipe - %v", err) |