-
Notifications
You must be signed in to change notification settings - Fork 21
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
prevent closing concurrently with other operations. #42
Conversation
f662088
to
e3515b3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for looking into this. Left a couple comments to look into.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM with one thing to check. Merge when you've either locked on i.Release()
or have confirmed that this isn't an issue (and left a comment in the code?).
b383d99
to
dbebcfb
Compare
Add a `sync.RWMutex` protecting the Close operation. Follows the same pattern as in go-ds-badger. Address #29 / ipfs/kubo#6880
dbebcfb
to
5d92b4d
Compare
Add a
sync.RWMutex
protecting the Close operation.Follows the same pattern as in go-ds-badger.
Address #29 / ipfs/kubo#6880