Fix segmentation fault issue when using WX port command line

on Linux and MacOS.
This commit is contained in:
Edênis Freindorfer Azevedo 2019-03-06 22:43:32 -03:00 committed by Rafael Kitover
parent 36453885fc
commit 7373da1528
2 changed files with 3 additions and 2 deletions

View File

@ -590,7 +590,8 @@ bool wxvbamApp::OnCmdLineParsed(wxCmdLineParser& cl)
}
wxvbamApp::~wxvbamApp() {
free(home);
if (home != NULL)
free(home);
}
MainFrame::MainFrame()

View File

@ -142,7 +142,7 @@ protected:
private:
wxPathList config_path;
char* home;
char* home = NULL;
};
DECLARE_APP(wxvbamApp);