VirtualQueryEx function kernel32
Win32Result<int>
VirtualQueryEx(
- HANDLE hProcess,
- Pointer<
NativeType> ? lpAddress, - Pointer<
MEMORY_BASIC_INFORMATION> lpBuffer, - int dwLength,
Retrieves information about a range of pages within the virtual address space of a specified process.
To learn more, see learn.microsoft.com/windows/win32/api/memoryapi/nf-memoryapi-virtualqueryex.
Implementation
Win32Result<int> VirtualQueryEx(
HANDLE hProcess,
Pointer? lpAddress,
Pointer<MEMORY_BASIC_INFORMATION> lpBuffer,
int dwLength,
) {
final result_ = VirtualQueryEx_Wrapper(
hProcess,
lpAddress ?? nullptr,
lpBuffer,
dwLength,
);
return .new(value: result_.value.i64, error: result_.error);
}