From 6a63d9e70e309d6360987570247f48a0c5135ee7 Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Tue, 10 Aug 2021 22:17:00 +0200 Subject: [PATCH] - moved the CheckForRestart call one level up so that it is within the Windows code and does not need #ifdefs. --- src/common/platform/win32/i_main.cpp | 2 ++ src/d_main.cpp | 4 ---- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/common/platform/win32/i_main.cpp b/src/common/platform/win32/i_main.cpp index bbada0fb2..acdfd2eb5 100644 --- a/src/common/platform/win32/i_main.cpp +++ b/src/common/platform/win32/i_main.cpp @@ -979,6 +979,8 @@ int DoMain (HINSTANCE hInstance) atexit (UnCOM); int ret = GameMain (); + CheckForRestart(); + DestroyCustomCursor(); if (ret == 1337) // special exit code for 'norun'. { diff --git a/src/d_main.cpp b/src/d_main.cpp index e29cca2db..245922beb 100644 --- a/src/d_main.cpp +++ b/src/d_main.cpp @@ -3716,10 +3716,6 @@ int GameMain() DeleteStartupScreen(); delete Args; Args = nullptr; -#ifdef _WIN32 - void CheckForRestart(); - CheckForRestart(); -#endif return ret; }