Save prefs explicitly, not in ~PrefsManager, so we don't try to save
if one of the other classes threw an exception.
This commit is contained in:
@@ -73,8 +73,6 @@ PrefsManager::PrefsManager()
|
|||||||
|
|
||||||
PrefsManager::~PrefsManager()
|
PrefsManager::~PrefsManager()
|
||||||
{
|
{
|
||||||
SaveGlobalPrefsToDisk();
|
|
||||||
SaveGamePrefsToDisk();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void PrefsManager::ReadGlobalPrefsFromDisk( bool bSwitchToLastPlayedGame )
|
void PrefsManager::ReadGlobalPrefsFromDisk( bool bSwitchToLastPlayedGame )
|
||||||
|
|||||||
@@ -375,6 +375,9 @@ int main(int argc, char* argv[])
|
|||||||
/* Run the main loop. */
|
/* Run the main loop. */
|
||||||
GameLoop();
|
GameLoop();
|
||||||
|
|
||||||
|
PREFSMAN->SaveGlobalPrefsToDisk();
|
||||||
|
PREFSMAN->SaveGamePrefsToDisk();
|
||||||
|
|
||||||
#ifndef _DEBUG
|
#ifndef _DEBUG
|
||||||
}
|
}
|
||||||
catch( RageException e )
|
catch( RageException e )
|
||||||
|
|||||||
Reference in New Issue
Block a user