From 0cd57b7712e223410666fe9d3f9d2b5dfa3a2864 Mon Sep 17 00:00:00 2001 From: SteelT Date: Sat, 14 Oct 2023 23:06:03 -0400 Subject: [PATCH] Fix linux crash on quit --- src/sdl/i_system.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/sdl/i_system.cpp b/src/sdl/i_system.cpp index 872ea6bff..559597552 100644 --- a/src/sdl/i_system.cpp +++ b/src/sdl/i_system.cpp @@ -1594,18 +1594,18 @@ INT32 I_StartupSystem(void) SDL_version SDLlinked; SDL_VERSION(&SDLcompiled) SDL_GetVersion(&SDLlinked); -#ifdef HAVE_THREADS - I_start_threads(); - I_AddExitFunc(I_stop_threads); - I_ThreadPoolInit(); - I_AddExitFunc(I_ThreadPoolShutdown); -#endif I_StartupConsole(); #ifdef NEWSIGNALHANDLER // This is useful when debugging. It lets GDB attach to // the correct process easily. if (!M_CheckParm("-nofork")) I_Fork(); +#endif +#ifdef HAVE_THREADS + I_start_threads(); + I_AddExitFunc(I_stop_threads); + I_ThreadPoolInit(); + I_AddExitFunc(I_ThreadPoolShutdown); #endif I_RegisterSignals(); I_OutputMsg("Compiled for SDL version: %d.%d.%d\n",