mirror of
https://github.com/amnezia-vpn/amneziawg-go.git
synced 2026-05-17 08:15:49 +03:00
fix(tests): compatibility fixes
This commit is contained in:
committed by
Yaroslav Gurov
parent
68e519c963
commit
8d2de9eb72
@@ -6,6 +6,7 @@
|
||||
package ipc
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"net"
|
||||
|
||||
"github.com/amnezia-vpn/amneziawg-go/ipc/namedpipe"
|
||||
@@ -69,7 +70,7 @@ func UAPIListen(name string) (net.Listener, error) {
|
||||
listener, err := (&namedpipe.ListenConfig{
|
||||
SecurityDescriptor: UAPISecurityDescriptor,
|
||||
}).Listen(path)
|
||||
if err == windows.ERROR_INVALID_OWNER {
|
||||
if errors.Is(err, windows.ERROR_INVALID_OWNER) {
|
||||
listener, err = (&namedpipe.ListenConfig{
|
||||
SecurityDescriptor: UAPIFallbackSecurityDescriptor,
|
||||
}).Listen(path)
|
||||
|
||||
Reference in New Issue
Block a user