0x7F000000-0x7FFFFFFF is magic.

This commit is contained in:
gibbed
2015-05-22 02:20:05 -05:00
parent b74859dda3
commit ea99ba8e3b
2 changed files with 4 additions and 2 deletions

View File

@@ -231,7 +231,7 @@ SHIM_CALL NtQueryVirtualMemory_shim(PPCContext* ppc_state, KernelState* state) {
auto heap = state->memory()->LookupHeap(base_address);
HeapAllocationInfo alloc_info;
if (!heap->QueryRegionInfo(base_address, &alloc_info)) {
if (heap == nullptr || !heap->QueryRegionInfo(base_address, &alloc_info)) {
SHIM_SET_RETURN_32(X_STATUS_INVALID_PARAMETER);
return;
}