Skip to content

Commit 13de00e

Browse files
committed
Prioritize rust Panic msg
1 parent 7cddc42 commit 13de00e

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

libdd-crashtracker/src/collector/crash_handler.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -322,15 +322,15 @@ fn handle_posix_signal_impl(
322322
// Get the panic message pointer but don't dereference or deallocate in signal handler.
323323
// The collector child process will handle converting this to a String after forking.
324324
// Leak of the message pointer is ok here.
325-
let message_ptr = PANIC_MESSAGE.swap(ptr::null_mut(), SeqCst);
325+
let panic_message_ptr = PANIC_MESSAGE.swap(ptr::null_mut(), SeqCst);
326326

327327
// If there is no panic message, check for a stored assert-failure message.
328328
// C assert() calls __assert_fail which we intercept to capture the
329329
// assertion expression before abort() raises SIGABRT.
330-
let message_ptr = if message_ptr.is_null() {
330+
let message_ptr = if panic_message_ptr.is_null() {
331331
super::assert_interceptor::take_assert_message_ptr()
332332
} else {
333-
message_ptr
333+
panic_message_ptr
334334
};
335335

336336
let timeout_manager = TimeoutManager::new(config.timeout());

0 commit comments

Comments
 (0)