diff options
Diffstat (limited to 'Kernel/Arch')
-rw-r--r-- | Kernel/Arch/x86/common/Interrupts.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Kernel/Arch/x86/common/Interrupts.cpp b/Kernel/Arch/x86/common/Interrupts.cpp index d5ddc1d2a6..64e41af52f 100644 --- a/Kernel/Arch/x86/common/Interrupts.cpp +++ b/Kernel/Arch/x86/common/Interrupts.cpp @@ -403,7 +403,9 @@ void page_fault_handler(TrapFrame* trap) if (current_thread) { auto& current_process = current_thread->process(); if (current_process.is_user_process()) { - (void)current_process.try_set_coredump_property("fault_address"sv, String::formatted("{:p}", fault_address)); + auto fault_address_string = KString::formatted("{:p}", fault_address); + auto fault_address_view = fault_address_string.is_error() ? ""sv : fault_address_string.value()->view(); + (void)current_process.try_set_coredump_property("fault_address"sv, fault_address_view); (void)current_process.try_set_coredump_property("fault_type"sv, fault.type() == PageFault::Type::PageNotPresent ? "NotPresent"sv : "ProtectionViolation"sv); StringView fault_access; if (fault.is_instruction_fetch()) |