From a65611da48a2c1630f6a5f79b92fdbf0c978e5af Mon Sep 17 00:00:00 2001 From: fufesou Date: Thu, 6 Apr 2023 12:02:01 +0800 Subject: [PATCH] do not handle signal on debug Signed-off-by: fufesou --- libs/hbb_common/src/platform/mod.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/libs/hbb_common/src/platform/mod.rs b/libs/hbb_common/src/platform/mod.rs index c1c766753..b109ac683 100644 --- a/libs/hbb_common/src/platform/mod.rs +++ b/libs/hbb_common/src/platform/mod.rs @@ -65,6 +65,7 @@ pub fn register_breakdown_handler(callback: T) where T: Fn() + 'static, { + #[cfg(not(debug_assertions))] unsafe { GLOBAL_CALLBACK = Some(Box::new(callback)); libc::signal(libc::SIGSEGV, breakdown_signal_handler as _);