mirror of
https://git.zx2c4.com/wireguard-go
synced 2024-11-15 01:05:15 +01:00
wintun: use correct length for security attributes
This commit is contained in:
parent
bb0b2514c0
commit
70f6c42556
@ -37,7 +37,7 @@ func initializeNamespace() error {
|
||||
return fmt.Errorf("SddlToSecurityDescriptor failed: %v", err)
|
||||
}
|
||||
wintunObjectSecurityAttributes = &windows.SecurityAttributes{
|
||||
Length: uint32(len(sd)),
|
||||
Length: uint32(unsafe.Sizeof(windows.SecurityAttributes{})),
|
||||
SecurityDescriptor: uintptr(unsafe.Pointer(&sd[0])),
|
||||
}
|
||||
sid, err := windows.CreateWellKnownSid(windows.WinLocalSystemSid)
|
||||
|
Loading…
Reference in New Issue
Block a user