DRC: Fix a minor memory leak
This commit is contained in:
parent
bc712a7383
commit
241823647b
|
@ -36,6 +36,13 @@ std::vector<KICAD_T> DRC_TEST_PROVIDER::s_allBasicItems;
|
|||
std::vector<KICAD_T> DRC_TEST_PROVIDER::s_allBasicItemsButZones;
|
||||
|
||||
|
||||
DRC_TEST_PROVIDER_REGISTRY::~DRC_TEST_PROVIDER_REGISTRY()
|
||||
{
|
||||
for( DRC_TEST_PROVIDER* provider : m_providers )
|
||||
delete provider;
|
||||
}
|
||||
|
||||
|
||||
DRC_TEST_PROVIDER::DRC_TEST_PROVIDER() :
|
||||
m_drcEngine( nullptr )
|
||||
{
|
||||
|
@ -327,4 +334,4 @@ bool DRC_TEST_PROVIDER::isInvisibleText( const BOARD_ITEM* aItem ) const
|
|||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -37,8 +37,9 @@ class DRC_TEST_PROVIDER;
|
|||
class DRC_TEST_PROVIDER_REGISTRY
|
||||
{
|
||||
public:
|
||||
DRC_TEST_PROVIDER_REGISTRY() {};
|
||||
~DRC_TEST_PROVIDER_REGISTRY() {};
|
||||
DRC_TEST_PROVIDER_REGISTRY() {}
|
||||
|
||||
~DRC_TEST_PROVIDER_REGISTRY();
|
||||
|
||||
static DRC_TEST_PROVIDER_REGISTRY& Instance()
|
||||
{
|
||||
|
@ -72,7 +73,7 @@ class DRC_TEST_PROVIDER
|
|||
{
|
||||
public:
|
||||
DRC_TEST_PROVIDER ();
|
||||
virtual ~DRC_TEST_PROVIDER() {}
|
||||
virtual ~DRC_TEST_PROVIDER() = default;
|
||||
|
||||
void SetDRCEngine( DRC_ENGINE *engine )
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue