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

Buffer response channel to prevent deadlock #4386

Merged
merged 1 commit into from Nov 13, 2017

Conversation

whyrusleeping
Copy link
Member

If a sessions context gets canceled during an isInterested request, bitswap (all of bitswap) can deadlock.

License: MIT
Signed-off-by: Jeromy jeromyj@gmail.com

License: MIT
Signed-off-by: Jeromy <jeromyj@gmail.com>
@ghost ghost assigned whyrusleeping Nov 13, 2017
@ghost ghost added the status/in-progress In progress label Nov 13, 2017
Copy link
Member

@dignifiedquire dignifiedquire left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This one simple trick they don’t want you to lnow about, that prevents your code from deadlocking.

@whyrusleeping whyrusleeping merged commit 27c4b5c into master Nov 13, 2017
@ghost ghost removed the status/in-progress In progress label Nov 13, 2017
@whyrusleeping whyrusleeping deleted the fix/session-cancel-deadlock branch November 13, 2017 16:51
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.

None yet

3 participants