kfunk added a comment.
I think the `QSharedPointer` overhead is very much negligible in this case here. And doesn't require refactoring of the original code. This is not performance sensitive code (compared to the costs of the QAIM-modifications), no? If you think the memory leak can be fixed differently, shoot. INLINE COMMENTS > kastatsfavoritesmodel.cpp:297 > > m_itemEntries[resource] > = m_itemEntries[entry->id()] With `std::unique_ptr` we'd run into a couple of problems, like in this place here: Multiple copies would be needed. REPOSITORY R119 Plasma Desktop REVISION DETAIL https://phabricator.kde.org/D17039 To: kfunk, davidedmundson, ivan Cc: plasma-devel, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart