Private helper to check if a system needs to be quit. */
| 120 | |
| 121 | /* Private helper to check if a system needs to be quit. */ |
| 122 | static SDL_bool |
| 123 | SDL_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 | |
| 135 | void |
| 136 | SDL_SetMainReady(void) |
no test coverage detected