- fixed memory leaks in map editor, g3dviewer and the game

This commit is contained in:
Mark Vejvoda
2012-07-21 20:21:27 +00:00
parent 8d168bdb4c
commit e1054d6e07
4 changed files with 34 additions and 3 deletions

View File

@@ -284,7 +284,8 @@ MainWindow::MainWindow( std::pair<string,vector<string> > unitToLoad,
wxSize(Renderer::windowW, Renderer::windowH)),
model(NULL), glCanvas(NULL), renderer(NULL),
initTextureManager(true), timer(NULL),
startupSettingsInited(false)
startupSettingsInited(false),
fileDialog(NULL)
{
this->appPath = appPath;
Properties::setApplicationPath(executable_path(appPath));
@@ -531,6 +532,9 @@ MainWindow::~MainWindow(){
delete timer;
timer = NULL;
delete fileDialog;
fileDialog = NULL;
delete model;
model = NULL;