Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix memory leak of vector type #1

Merged
merged 1 commit into from
Jan 19, 2024
Merged

fix memory leak of vector type #1

merged 1 commit into from
Jan 19, 2024

Conversation

UnpureRationalist
Copy link

Hi there,

Thanks for your excellent tutotial for vector database beginners. When I follow your tutorial and test my implementions using the commands here, memory leak was reported by AddressSanitizer.

After debugging, I found the destructor of class Value was not implemented well for VECTOR type. So this PR fixed the bug by modifying destructor along with the copy constructor (The copy assignment operator do not need to change since it is pass by value).

After fixing the bug, the test can passed correctly without memory leak.

@skyzh
Copy link
Owner

skyzh commented Jan 19, 2024

Thanks!

@skyzh skyzh merged commit 74de667 into skyzh:main Jan 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants