mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-07-27 12:34:37 +00:00
Fix fix fix
Should prevent infinite loops, haven't tested properly yet though.
This commit is contained in:
parent
a8b865e783
commit
409e5248e5
@ -352,7 +352,7 @@ int MemoryManager::MapMemory(void** out_addr, VAddr virtual_addr, size_t size, M
|
|||||||
// To account for this, unmap any reserved areas within this mapping range first.
|
// To account for this, unmap any reserved areas within this mapping range first.
|
||||||
auto unmap_addr = mapped_addr;
|
auto unmap_addr = mapped_addr;
|
||||||
auto unmap_size = size;
|
auto unmap_size = size;
|
||||||
while (!vma.IsMapped() && vma.base < mapped_addr + size && remaining_size < size) {
|
while (!vma.IsMapped() && unmap_addr < mapped_addr + size && remaining_size < size) {
|
||||||
auto unmapped = UnmapBytesFromEntry(unmap_addr, vma, unmap_size);
|
auto unmapped = UnmapBytesFromEntry(unmap_addr, vma, unmap_size);
|
||||||
unmap_addr += unmapped;
|
unmap_addr += unmapped;
|
||||||
unmap_size -= unmapped;
|
unmap_size -= unmapped;
|
||||||
|
Loading…
Reference in New Issue
Block a user