From 1518177efac38961a36db0bc40152d00c38e6281 Mon Sep 17 00:00:00 2001 From: Fabian Imhof Date: Sun, 27 Oct 2024 13:27:33 +0000 Subject: add correct optional handling --- arch/x86_64/include/arch/memory/paging/page_table.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'arch/x86_64/include') diff --git a/arch/x86_64/include/arch/memory/paging/page_table.hpp b/arch/x86_64/include/arch/memory/paging/page_table.hpp index 291ea8d..8fcde9f 100644 --- a/arch/x86_64/include/arch/memory/paging/page_table.hpp +++ b/arch/x86_64/include/arch/memory/paging/page_table.hpp @@ -83,7 +83,7 @@ namespace teachos::arch::memory::paging // been created itself. So we have to do that before we are able to allocate the wanted frame. This has to be done // for every level, meaning we potenitally create a level 4, level 3 and level 2 page entry, each pointing to a // page table one level below. - if (!next_handle) + if (!next_handle.has_value()) { auto allocated_frame = allocator.allocate_frame(); exception_handling::assert(allocated_frame.has_value(), "[Page mapper] Unable to allocate frame"); -- cgit v1.2.3