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

Mark arrays as free before releasing the data. #511

Merged
merged 1 commit into from
Jan 9, 2024

Conversation

maleadt
Copy link
Member

@maleadt maleadt commented Jan 9, 2024

Otherwise the GC can call unsafe_free while we were performing a manual unsafe_free.

We could make the freed field of DataRef atomic, but currently operations on the parent object aren't supposed to be thread-safe. Only the contained RefCounted is.

Fixes #503

Otherwise the GC can call unsafe_free while we were performing
a manual unsafe_free.
@maleadt maleadt merged commit a689dff into master Jan 9, 2024
14 checks passed
@maleadt maleadt deleted the tb/concurrent_finalization branch January 9, 2024 17:18
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.

unsafe_free! is not thread-safe
1 participant