Fixed a potential segfault of application exit

This commit is contained in:
Matthias Koefferlein 2023-08-03 19:22:11 +02:00
parent 7509e7a18c
commit f583d5e3db
1 changed files with 4 additions and 0 deletions

View File

@ -327,6 +327,10 @@ Plugin::~Plugin ()
if (mp_parent) {
mp_parent->unregister_plugin (this);
}
// remove us from the children's parent
for (auto c = m_children.begin (); c != m_children.end (); ++c) {
c->mp_parent = 0;
}
}
void