From ef22c9394534014dbda3e2a070df3d02a9fd041e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matteo=20Gm=C3=BCr?= Date: Tue, 22 Oct 2024 09:22:04 +0000 Subject: Remove default initalization of member variables --- arch/x86_64/include/arch/memory/paging/page_entry.hpp | 4 ++-- arch/x86_64/include/arch/memory/paging/page_mapper.hpp | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) (limited to 'arch/x86_64/include') diff --git a/arch/x86_64/include/arch/memory/paging/page_entry.hpp b/arch/x86_64/include/arch/memory/paging/page_entry.hpp index 73aa554..9ca5469 100644 --- a/arch/x86_64/include/arch/memory/paging/page_entry.hpp +++ b/arch/x86_64/include/arch/memory/paging/page_entry.hpp @@ -85,8 +85,8 @@ namespace teachos::arch::memory::paging */ auto calculate_physical_address() const -> std::size_t; - std::bitset<64U> flags = {}; ///< Underlying bitset used to read the flags from. Bits 9 - 11 and 52 - 62 can be - ///< freely used for additional flags by the operating system. + std::bitset<64U> flags; ///< Underlying bitset used to read the flags from. Bits 9 - 11 and 52 - 62 can be + ///< freely used for additional flags by the operating system. }; } // namespace teachos::arch::memory::paging diff --git a/arch/x86_64/include/arch/memory/paging/page_mapper.hpp b/arch/x86_64/include/arch/memory/paging/page_mapper.hpp index 4735c13..80f6eb4 100644 --- a/arch/x86_64/include/arch/memory/paging/page_mapper.hpp +++ b/arch/x86_64/include/arch/memory/paging/page_mapper.hpp @@ -79,8 +79,7 @@ namespace teachos::arch::memory::paging // There should now be an entry at the previously not existent index, therefore we can simply access it again. next_handle = current_handle.next_table(level_index); exception_handling::assert(next_handle.has_value(), "[Page mapper] Unable to create new entry into page table"); - - // TODO: Crashes here! + // TODO: Crashes when trying to access underlying entries array. next_handle.value().zero_entries(); } current_handle = next_handle.value(); -- cgit v1.2.3