mirror of
https://github.com/leozide/leocad.git
synced 2026-07-28 04:07:11 +00:00
Remove views in destructor
- This avoid a use-after-free when the view remove itself in its dtor
This commit is contained in:
@@ -45,6 +45,13 @@ public:
|
||||
mModel = Model;
|
||||
mActiveView = nullptr;
|
||||
}
|
||||
~lcModelTabWidget()
|
||||
{
|
||||
for (auto View : mViews)
|
||||
{
|
||||
RemoveView(View);
|
||||
}
|
||||
}
|
||||
|
||||
void ResetLayout();
|
||||
void Clear();
|
||||
|
||||
Reference in New Issue
Block a user