mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-06-03 10:27:40 +00:00
dynapi: trigger a breakpoint on a fatal error when SDL is built in debug mode
This commit is contained in:
parent
6cf6b160cd
commit
3842384a38
1 changed files with 3 additions and 0 deletions
|
@ -520,6 +520,9 @@ static void SDL_InitDynamicAPILocked(void)
|
||||||
if (initialize_jumptable(SDL_DYNAPI_VERSION, &jump_table, sizeof(jump_table)) < 0) {
|
if (initialize_jumptable(SDL_DYNAPI_VERSION, &jump_table, sizeof(jump_table)) < 0) {
|
||||||
// Now we're screwed. Should definitely abort now.
|
// Now we're screwed. Should definitely abort now.
|
||||||
dynapi_warn("Failed to initialize internal SDL dynapi. As this would otherwise crash, we have to abort now.");
|
dynapi_warn("Failed to initialize internal SDL dynapi. As this would otherwise crash, we have to abort now.");
|
||||||
|
#ifndef NDEBUG
|
||||||
|
SDL_TriggerBreakpoint();
|
||||||
|
#endif
|
||||||
SDL_ExitProcess(86);
|
SDL_ExitProcess(86);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue