Merge pull request #788 from benridley/bugfix_sysinfo_layout

Correct layout of SystemInfo structs
This commit is contained in:
Calle Pettersson 2021-05-21 09:41:34 +02:00 committed by GitHub
commit 74eac8f29b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

View File

@ -36,8 +36,8 @@ type MemoryStatus struct {
// wProcessorArchitecture is a wrapper for the union found in LP_SYSTEM_INFO
// https://docs.microsoft.com/en-us/windows/win32/api/sysinfoapi/ns-sysinfoapi-system_info
type wProcessorArchitecture struct {
WReserved uint16
WProcessorArchitecture uint16
WReserved uint16
}
// ProcessorArchitecture is an idiomatic wrapper for wProcessorArchitecture
@ -60,7 +60,7 @@ type lpSystemInfo struct {
DwPageSize uint32
LpMinimumApplicationAddress uintptr
LpMaximumApplicationAddress uintptr
DwActiveProcessorMask uint32
DwActiveProcessorMask uint
DwNumberOfProcessors uint32
DwProcessorType uint32
DwAllocationGranularity uint32
@ -74,7 +74,7 @@ type SystemInfo struct {
PageSize uint32
MinimumApplicationAddress uintptr
MaximumApplicationAddress uintptr
ActiveProcessorMask uint32
ActiveProcessorMask uint
NumberOfProcessors uint32
ProcessorType uint32
AllocationGranularity uint32