mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-03-20 15:51:07 +01:00
testprogram: let main() return normally, don't exit for platform (eg Android) where there is some cleanup afterward.
This commit is contained in:
@@ -22,7 +22,7 @@
|
||||
static SDL_TLSID tls;
|
||||
static int alive = 0;
|
||||
static int testprio = 0;
|
||||
SDLTest_CommonState *state;
|
||||
static SDLTest_CommonState *state;
|
||||
|
||||
/* Call this instead of exit(), so we can clean up SDL: atexit() is evil. */
|
||||
static void
|
||||
@@ -30,7 +30,10 @@ quit(int rc)
|
||||
{
|
||||
SDLTest_CommonDestroyState(state);
|
||||
SDL_Quit();
|
||||
exit(rc);
|
||||
/* Let 'main()' return normally */
|
||||
if (rc != 0) {
|
||||
exit(rc);
|
||||
}
|
||||
}
|
||||
|
||||
static const char *
|
||||
|
||||
Reference in New Issue
Block a user