From 06b73eea94a695f6a9f2c6bdd89e839e262b7da2 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Boric Date: Wed, 20 Jan 2021 20:28:26 +0100 Subject: Kernel: Do not assert if unable to load kernel symbols --- Kernel/KSyms.cpp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/Kernel/KSyms.cpp b/Kernel/KSyms.cpp index fe0db7add4..6ccf816af6 100644 --- a/Kernel/KSyms.cpp +++ b/Kernel/KSyms.cpp @@ -191,11 +191,12 @@ void dump_backtrace() void load_kernel_symbol_table() { auto result = VFS::the().open("/res/kernel.map", O_RDONLY, 0, VFS::the().root_custody()); - ASSERT(!result.is_error()); - auto description = result.value(); - auto buffer = description->read_entire_file(); - ASSERT(!buffer.is_error()); - load_kernel_sybols_from_data(*buffer.value()); + if (!result.is_error()) { + auto description = result.value(); + auto buffer = description->read_entire_file(); + if (!buffer.is_error()) + load_kernel_sybols_from_data(*buffer.value()); + } } } -- cgit v1.2.3