HaikuDepot: Cleanup and release references early.
So that we do not destroy things in the wrong order and trigger the reference-counting assertions. Fixes #17579.
This commit is contained in:
parent
1e7094566a
commit
d556224730
@ -292,6 +292,13 @@ MainWindow::~MainWindow()
|
||||
if (fShuttingDownWindow->Lock())
|
||||
fShuttingDownWindow->Quit();
|
||||
}
|
||||
|
||||
// We must clear and delete these early to release references.
|
||||
fModel.Clear();
|
||||
fFeaturedPackagesView->RemoveSelf();
|
||||
fPackageListView->RemoveSelf();
|
||||
delete fFeaturedPackagesView;
|
||||
delete fPackageListView;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user