mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-06 08:36:15 +00:00
Kernel: Actually fix accidental overlaps in allocate_range_specific()
Thanks to Idan for spotting this! :^)
This commit is contained in:
@@ -90,7 +90,7 @@ ErrorOr<VirtualRange> RegionTree::allocate_range_specific(VirtualAddress base, s
|
||||
if (!m_total_range.contains(range))
|
||||
return ENOMEM;
|
||||
|
||||
auto* region = m_regions.find_largest_not_above(base.offset(size).get());
|
||||
auto* region = m_regions.find_largest_not_above(base.offset(size - 1).get());
|
||||
if (!region) {
|
||||
// The range can be accommodated below the current lowest range.
|
||||
return range;
|
||||
|
||||
Reference in New Issue
Block a user