MXS-2612 Ensure that destructor order does not matter

The new configuration system relieas upon static varibles being
used for declaring what arguments a particular module uses. To
ensure that the destruction order does not matter, we redundantly
store the needed data (the name).
This commit is contained in:
Johan Wikman
2019-08-28 15:59:45 +03:00
parent 0bb53bf411
commit 5a7c68e3c9
2 changed files with 11 additions and 6 deletions

View File

@ -883,7 +883,7 @@ private:
friend Type;
void insert(Type* pValue);
void remove(Type* pValue);
void remove(Type* pValue, const std::string& name);
private:
std::string m_name;
@ -946,8 +946,9 @@ protected:
Type(Configuration* pConfiguration, const Param* pParam);
private:
Configuration& m_configuration;
const Param& m_param;
Configuration& m_configuration;
const Param& m_param;
const std::string m_name;
};
/**