diff --git a/cmd/syncthing/memsize_windows.go b/cmd/syncthing/memsize_windows.go index a778f77e6..b993c0432 100644 --- a/cmd/syncthing/memsize_windows.go +++ b/cmd/syncthing/memsize_windows.go @@ -20,9 +20,8 @@ var ( func memorySize() (int64, error) { var memoryStatusEx [64]byte binary.LittleEndian.PutUint32(memoryStatusEx[:], 64) - p := uintptr(unsafe.Pointer(&memoryStatusEx[0])) - ret, _, callErr := syscall.Syscall(uintptr(globalMemoryStatusEx), 1, p, 0, 0) + ret, _, callErr := syscall.Syscall(uintptr(globalMemoryStatusEx), 1, uintptr(unsafe.Pointer(&memoryStatusEx[0])), 0, 0) if ret == 0 { return 0, callErr }