MCPcopy Create free account
hub / github.com/RavEngine/RavEngine / SDL_PrivateShouldQuitSubsystem

Function SDL_PrivateShouldQuitSubsystem

deps/SDL2/src/SDL.c:122–133  ·  view source on GitHub ↗

Private helper to check if a system needs to be quit. */

Source from the content-addressed store, hash-verified

120
121/* Private helper to check if a system needs to be quit. */
122static SDL_bool
123SDL_PrivateShouldQuitSubsystem(Uint32 subsystem) {
124 int subsystem_index = SDL_MostSignificantBitIndex32(subsystem);
125 if (SDL_SubsystemRefCount[subsystem_index] == 0) {
126 return SDL_FALSE;
127 }
128
129 /* If we're in SDL_Quit, we shut down every subsystem, even if refcount
130 * isn't zero.
131 */
132 return (SDL_SubsystemRefCount[subsystem_index] == 1 || SDL_bInMainQuit) ? SDL_TRUE : SDL_FALSE;
133}
134
135void
136SDL_SetMainReady(void)

Callers 1

SDL_QuitSubSystemFunction · 0.85

Calls 1

Tested by

no test coverage detected