mirror of
https://github.com/rive-app/rive-cpp.git
synced 2026-01-18 21:21:17 +01:00
Update our signal handler to break into the Windows debugger if it's attached (#11015) d9b3ed9801
Update our signal handler to break into the debugger if it's attached on Windows Co-authored-by: Josh Jersild <joshua@rive.app>
This commit is contained in:
@@ -1 +1 @@
|
||||
0743b80014494dd786f750b0a9cf109b32ef573a
|
||||
d9b3ed98012c56fa6a8b4f586ff3488385f376f9
|
||||
|
||||
@@ -175,6 +175,15 @@ static void handle_signal(int signo) noexcept
|
||||
build_stack(signo);
|
||||
// set the signal handler to the original
|
||||
signal(signo, SIG_DFL);
|
||||
|
||||
#ifdef _WIN32
|
||||
if (IsDebuggerPresent())
|
||||
{
|
||||
// Cause the debugger to break
|
||||
DebugBreak();
|
||||
}
|
||||
#endif
|
||||
|
||||
// re raise the signal
|
||||
raise(signo);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user