aboutsummaryrefslogtreecommitdiff
path: root/arch/x86_64/src/kernel
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86_64/src/kernel')
-rw-r--r--arch/x86_64/src/kernel/main.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/arch/x86_64/src/kernel/main.cpp b/arch/x86_64/src/kernel/main.cpp
index 12498d0..babe251 100644
--- a/arch/x86_64/src/kernel/main.cpp
+++ b/arch/x86_64/src/kernel/main.cpp
@@ -165,7 +165,6 @@ namespace teachos::arch::kernel
auto allocator = arch::memory::area_frame_allocator(kernel_start, kernel_end, multiboot_start, multiboot_end,
memory_areas, area_count);
- // WATCH OUT: using optional::value() crashes the build... I think its because of missing exception handling
auto last_allocated = allocator.allocate_frame();
auto allocated = last_allocated;
do
@@ -174,6 +173,6 @@ namespace teachos::arch::kernel
allocated = allocator.allocate_frame();
} while (allocated.has_value());
video::vga::text::write("Allocated Frames", video::vga::text::common_attributes::green_on_black);
- video::vga::text::write_number(allocated->frame_number, video::vga::text::common_attributes::green_on_black);
+ video::vga::text::write_number(allocated.value().frame_number, video::vga::text::common_attributes::green_on_black);
}
} // namespace teachos::arch::kernel