mirror of
https://github.com/amnezia-vpn/amneziawg-go.git
synced 2025-04-16 14:06:54 +02:00
Fix code duplication
This commit is contained in:
parent
dd663a7ba4
commit
794e494802
1 changed files with 0 additions and 5 deletions
|
@ -340,11 +340,6 @@ func CreateTUNFromFile(file *os.File) (TUNDevice, error) {
|
|||
return nil, err
|
||||
}
|
||||
|
||||
if err != nil {
|
||||
tun.fd.Close()
|
||||
return nil, err
|
||||
}
|
||||
|
||||
tun.rwcancel, err = rwcancel.NewRWCancel(int(file.Fd()))
|
||||
if err != nil {
|
||||
tun.fd.Close()
|
||||
|
|
Loading…
Add table
Reference in a new issue