Skip to content

Commit 85c736b

Browse files
committed
Also display panic message when panicking
1 parent 0bdf1a0 commit 85c736b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

uefi-services/src/lib.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,10 +95,11 @@ fn eh_personality() {}
9595

9696
#[lang = "panic_fmt"]
9797
#[no_mangle]
98-
pub fn panic_fmt(_fmt: core::fmt::Arguments, file_line_col: &(&'static str, u32, u32)) {
98+
pub fn panic_fmt(fmt: core::fmt::Arguments, file_line_col: &(&'static str, u32, u32)) {
9999
let &(file, line, column) = file_line_col;
100100

101-
error!("Panic in {} at ({}, {})", file, line, column);
101+
error!("Panic in {} at ({}, {}):", file, line, column);
102+
error!("{}", fmt);
102103

103104
loop {
104105
// TODO: add a timeout then shutdown.

0 commit comments

Comments
 (0)