mirror of
https://github.com/kubenetworks/kubevpn.git
synced 2025-12-24 11:51:13 +08:00
feat: optimize code
This commit is contained in:
@@ -33,11 +33,11 @@ func InstallWireGuardTunDriver() {
|
||||
}
|
||||
|
||||
func UninstallWireGuardTunDriver() error {
|
||||
wd, err := os.Getwd()
|
||||
executable, err := os.Executable()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
filename := filepath.Join(wd, "wintun.dll")
|
||||
filename := filepath.Join(filepath.Dir(executable), "wintun.dll")
|
||||
return os.Remove(filename)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user