Skip to content

Commit 32c2765

Browse files
committedNov 9, 2018
Update win tuntap
1 parent 4f65fab commit 32c2765

File tree

1 file changed

+3
-10
lines changed

1 file changed

+3
-10
lines changed
 

‎tuntap_win/tuntap.go

+3-10
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,7 @@ func main() {
1313
panic(err)
1414
}
1515

16-
tuntapDir := ""
17-
if os.Getenv("PROGRAMFILES(X86)") == "" {
18-
tuntapDir = filepath.Join(rootDir, "32")
19-
} else {
20-
tuntapDir = filepath.Join(rootDir, "64")
21-
}
22-
23-
tapInstallPath := path.Join(tuntapDir, "tapinstall.exe")
16+
tapInstallPath := path.Join(rootDir, "tapinstall.exe")
2417

2518
if os.Args[1] == "install" {
2619
cmd := exec.Command(
@@ -29,7 +22,7 @@ func main() {
2922
"OemVista.inf",
3023
"tap0901",
3124
)
32-
cmd.Dir = tuntapDir
25+
cmd.Dir = rootDir
3326

3427
err = cmd.Run()
3528
if err != nil {
@@ -41,7 +34,7 @@ func main() {
4134
"remove",
4235
"tap0901",
4336
)
44-
cmd.Dir = tuntapDir
37+
cmd.Dir = rootDir
4538

4639
err = cmd.Run()
4740
if err != nil {

0 commit comments

Comments
 (0)
Please sign in to comment.