mirror of
https://github.com/LizardByte/Sunshine.git
synced 2025-08-10 00:52:16 +00:00
Use a common function to abort for debugging purposes
This commit is contained in:
@@ -166,6 +166,18 @@ namespace lifetime {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Breaks into the debugger or terminates Sunshine if no debugger is attached.
|
||||
*/
|
||||
void
|
||||
debug_trap() {
|
||||
#ifdef _WIN32
|
||||
DebugBreak();
|
||||
#else
|
||||
std::raise(SIGTRAP);
|
||||
#endif
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Gets the argv array passed to main().
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user