Allow GetPhysicalRef to hold a past-the-end offset (#6141)
Games will sometimes use these when representing open right bounds and so disallowing it caused regressions, with a notable example being when MemoryFill is called to the end of vram, causing an "invalid end address" error. This had been noted on a comment in GetPhysicalRef prior to the regression.
This commit is contained in:
@ -496,7 +496,7 @@ MemoryRef MemorySystem::GetPhysicalRef(PAddr address) const {
|
||||
default:
|
||||
UNREACHABLE();
|
||||
}
|
||||
if (offset_into_region >= target_mem->GetSize()) {
|
||||
if (offset_into_region > target_mem->GetSize()) {
|
||||
return {nullptr};
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user