I am getting the below warning message from the static code analysis tool:
dtor_in_derived: Class CActivation has a destructor and a pointer to it is upcast to class IOperation which doesn't have a virtual destructor.
Below is my code snippet:
CActivation.h file
class CActivation : public IOperation
{
public:
CActivation();
~CActivation();
};
CActivation.cpp file
CActivation::CActivation()
{
CoInitialize(0);
}
CActivation::~CActivation()
{
CoUninitialize();
}
IOperation.h file
class IOperation
{
public:
IOperation();
~IOperation();
};
Could anyone please help me with the root cause?
Aucun commentaire:
Enregistrer un commentaire