CodeEdit
CodeEdit copied to clipboard
fix: Searchkit memory leaks
Description
This PR fixes some memory leaks that occurred during the retrieval of search results from SearchKit. This was because I wrongfully used .takeUnretainedValue(), which caused the memory count to be off, leading to thousands of objects not being deinitialized.
I reviewed all the code that uses SearchKit and corrected other instances of wrongful use of .takeUnretainedValue() or .takeRetainedValue().
During profiling, there should no longer be any memory leaks connected to SearchKit.
Related Issues
- closes #1736
Checklist
- [x] I read and understood the contributing guide as well as the code of conduct
- [x] The issues this PR addresses are related to each other
- [x] My changes generate no new warnings
- [x] My code builds and runs on my machine
- [x] My changes are all related to the related issue above
- [x] I documented my code