Fix : Game not saved when exit button is used.

This commit is contained in:
Laurent Marchelli 2016-03-13 22:30:46 +01:00
parent 2b53a2c0a1
commit 7bfddb5692
1 changed files with 5 additions and 22 deletions

View File

@ -350,28 +350,11 @@ void EnterMessageLoop ()
ContinueExecution();
if (g_nAppMode != MODE_DEBUG)
{
if (joyexitenable)
{
CheckJoyExit();
if (joyquitevent)
{
if(g_fh)
{
fprintf(g_fh,"*** Logging ended\n\n");
fclose(g_fh);
}
RiffFinishWriteFile();
fclose(registry); //close conf file (linapple.conf by default)
SDL_Quit();
// CURL routines
curl_easy_cleanup(g_curl);
curl_global_cleanup();
printf("Linapple: successfully exited!\n");
std::_Exit(0);
}
}
if (joyexitenable)
{
CheckJoyExit();
if (joyquitevent) return;
}
if (g_bFullSpeed)
ContinueExecution();
}