diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2019-09-16 19:38:05 -0600 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2019-09-23 15:29:18 +0200 |
commit | 9c3c15a7ff88c8ff670f534a9575fe54811ef8c2 (patch) | |
tree | 527668dfac6c929b1509a59e006dfb43b8ed0e5e | |
parent | firewall: remove unused wrappers (diff) | |
download | wireguard-windows-9c3c15a7ff88c8ff670f534a9575fe54811ef8c2.tar.xz wireguard-windows-9c3c15a7ff88c8ff670f534a9575fe54811ef8c2.zip |
updater: use correct length for security attributes
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to '')
-rw-r--r-- | updater/msirunner_windows.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/updater/msirunner_windows.go b/updater/msirunner_windows.go index 62ec1cdf..6b8ae476 100644 --- a/updater/msirunner_windows.go +++ b/updater/msirunner_windows.go @@ -66,7 +66,7 @@ func msiTempFile() (*os.File, error) { return nil, err } sa := &windows.SecurityAttributes{ - Length: uint32(len(sd)), + Length: uint32(unsafe.Sizeof(windows.SecurityAttributes{})), SecurityDescriptor: uintptr(unsafe.Pointer(&sd[0])), } // TODO: os.TempDir() returns C:\windows\temp when calling from this context. Supposedly this is mostly secure |