From 86092f3c83153e7b6cca1a00f41887416978f1f0 Mon Sep 17 00:00:00 2001 From: cloudwalk Date: Mon, 20 Jul 2020 17:35:02 +0000 Subject: [PATCH] host: Return to main() if the loop breaks and Sys_Quit from there git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12852 d7cf8633-e32d-0410-b094-e92efae38249 --- host.c | 2 +- sys_sdl.c | 2 ++ sys_unix.c | 2 ++ sys_win.c | 2 ++ 4 files changed, 7 insertions(+), 1 deletion(-) diff --git a/host.c b/host.c index afa18ec2..fdffa60f 100644 --- a/host.c +++ b/host.c @@ -515,7 +515,7 @@ void Host_Main(void) host.framecount++; } - Sys_Quit(0); + return; } //============================================================================ diff --git a/sys_sdl.c b/sys_sdl.c index 9285f55d..e57bd669 100644 --- a/sys_sdl.c +++ b/sys_sdl.c @@ -222,6 +222,8 @@ int main (int argc, char *argv[]) Host_Main(); + Sys_Quit(0); + return 0; } diff --git a/sys_unix.c b/sys_unix.c index 09929a37..4837d3ad 100644 --- a/sys_unix.c +++ b/sys_unix.c @@ -166,6 +166,8 @@ int main (int argc, char **argv) #endif Host_Main(); + Sys_Quit(0); + return 0; } diff --git a/sys_win.c b/sys_win.c index de8e266a..12b4174a 100644 --- a/sys_win.c +++ b/sys_win.c @@ -363,6 +363,8 @@ int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLin Host_Main(); + Sys_Quit(0); + /* return success of application */ return true; } -- 2.39.2