Kernel: Fix MemoryRegion overlap comparison

This made some calls to `munmap` unmap extra regions.
This commit is contained in:
Bananymous 2024-11-13 17:26:42 +02:00
parent 7542e55cb2
commit 64c52012df
1 changed files with 1 additions and 1 deletions

View File

@ -40,7 +40,7 @@ namespace Kernel
bool MemoryRegion::overlaps(vaddr_t address, size_t size) const bool MemoryRegion::overlaps(vaddr_t address, size_t size) const
{ {
if (address + size < m_vaddr) if (address + size <= m_vaddr)
return false; return false;
if (address >= m_vaddr + m_size) if (address >= m_vaddr + m_size)
return false; return false;