Fixed memory leaks

This is commit a9efbf47 with a fix for SWIG to deal with unique_ptr.
This commit is contained in:
Maciej Suminski
2018-12-20 10:05:58 +01:00
parent 22d8ddb207
commit 24f9bfa13b
12 changed files with 25 additions and 30 deletions
+1 -3
View File
@@ -79,7 +79,7 @@ private:
wxString m_ConvertedFileName;
wxSize m_frameSize;
wxPoint m_framePos;
wxConfigBase* m_config;
std::unique_ptr<wxConfigBase> m_config;
public:
BM2CMP_FRAME( KIWAY* aKiway, wxWindow* aParent );
@@ -223,8 +223,6 @@ BM2CMP_FRAME::~BM2CMP_FRAME()
m_config->Write( KEYWORD_LAST_FORMAT, m_radioBoxFormat->GetSelection() );
m_config->Write( KEYWORD_LAST_MODLAYER, m_radio_PCBLayer->GetSelection() );
delete m_config;
/* This needed for OSX: avoids further OnDraw processing after this
* destructor and before the native window is destroyed
*/