From c38e0ebdebd8a2f221a48153d041178e8a5b3bff Mon Sep 17 00:00:00 2001 From: Daniel Gibson Date: Fri, 21 Sep 2012 16:09:21 +0200 Subject: [PATCH] Fix freeze when quitting the game during timedemo When one tries to quit the game (via quit in console) while a timedemo is running, the game freezes indefinitely while displaying the timedemo results. This happens because the MessageBox used for that waits for a an event normally triggered by a timer - but it seems like that does not happen anymore during Shutdown() The fix makes sure that this message box isn't displayed. --- neo/framework/Session.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/neo/framework/Session.cpp b/neo/framework/Session.cpp index 3863c3d9..488b09a2 100644 --- a/neo/framework/Session.cpp +++ b/neo/framework/Session.cpp @@ -419,6 +419,11 @@ void idSessionLocal::Shutdown() { EndAVICapture(); } + if(timeDemo == TD_YES) { + // else the game freezes when showing the timedemo results + timeDemo = TD_YES_THEN_QUIT; + } + Stop(); if ( rw ) {