Fixed a nasty order of destruction bug, where the memory pool for ScriptInts was destroyed before the PackageManager

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@20 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2006-10-12 17:08:02 +00:00
parent 6fe45ca28b
commit b13d0b81ae
13 changed files with 257 additions and 41 deletions
+3
View File
@@ -7,6 +7,7 @@
// ----------------------------------------------------------------------------- : Includes
#include <util/prec.hpp>
#include <util/io/package_manager.hpp>
#include <data/game.hpp>
#include <data/set.hpp>
#include <data/settings.hpp>
@@ -51,6 +52,7 @@ bool MSE::OnInit() {
} catch (...) {
handle_error(InternalError(_("An unexpected exception occurred, this is a bug!\nPlease save your work (use 'save as' to so you don't overwrite things),\n and restart Magic Set Editor.\n\nYou can leave a bug report on http://magicseteditor.sourceforge.net/")), false);
}
packages.destroy();
return false;
}
@@ -58,6 +60,7 @@ bool MSE::OnInit() {
int MSE::OnExit() {
settings.write();
packages.destroy();
return 0;
}