Corrected illegal memory access bug after freeing hovered annotation item

This commit is contained in:
Nav
2021-12-25 03:10:01 +00:00
parent 45c6470548
commit d69a8bcde5

View File

@@ -90,6 +90,7 @@ void ByteItemGraphicsScene::refreshRegions() {
}
// Refresh annotation items
this->hoveredAnnotationItem = std::nullopt;
for (auto* annotationItem : this->annotationItems) {
this->removeItem(annotationItem);
delete annotationItem;