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()
|
||||
{
|
||||
SaveGlobalPrefsToDisk();
|
||||
SaveGamePrefsToDisk();
|
||||
}
|
||||
|
||||
void PrefsManager::ReadGlobalPrefsFromDisk( bool bSwitchToLastPlayedGame )
|
||||
|
||||
@@ -375,6 +375,9 @@ int main(int argc, char* argv[])
|
||||
/* Run the main loop. */
|
||||
GameLoop();
|
||||
|
||||
PREFSMAN->SaveGlobalPrefsToDisk();
|
||||
PREFSMAN->SaveGamePrefsToDisk();
|
||||
|
||||
#ifndef _DEBUG
|
||||
}
|
||||
catch( RageException e )
|
||||
|
||||
Reference in New Issue
Block a user