Commit 5b28980a authored by jean-pierre charras's avatar jean-pierre charras

Pcbnew, Cvpcb: fix Bug #1355883 . Due to a missing call to a delete operator...

Pcbnew, Cvpcb: fix Bug #1355883 . Due to a missing call to a delete operator in CMP_READER class (also creates memory leak).
parent 3a62a595
......@@ -55,11 +55,26 @@ class CMP_READER
LINE_READER* m_lineReader; ///< The line reader to read.
public:
/**
* CMP_READER constructor.
* @param aLineReader is a LINE_READER (in fact a FILE_LINE_READER)
* which is owned by me ( and deleted by me) to read
* the component footprint link file.
*/
CMP_READER( LINE_READER* aLineReader )
{
m_lineReader = aLineReader;
}
~CMP_READER()
{
if( m_lineReader )
{
delete m_lineReader;
m_lineReader = NULL;
}
}
/**
* Function Load
* read the *.cmp file format contains the component footprint assignments created by CvPcb
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment