-
Notifications
You must be signed in to change notification settings - Fork 140
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
Set channels and allocator to nil in shutdown #172
Conversation
will run some tests tomorrow to see how this behaves. |
I think due to the slash in the branch name, it's not trivially possible to go get this branch as dependency:
Edit: using the hash did the job:
|
tests still work. |
After 2d55559, we are setting some fields to nil in the shutdown sequence. We have to ensure that the library does not panic as a consequence, after the connection is closed. Signed-off-by: Aitor Perez Cedres <[email protected]>
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.
I added a test case to ensure that Connection.Channel()
won't panic, when called on a closed connection. A user may try to use a closed connection. In such case, the library should return an error (not panic).
@lukebakken happy with the code as is. Feel free to add your review to my test case before merging :) |
@jxsl13 - I'll keep that in mind for future PRs (don't use a slash). Thanks for testing. |
Thanks for maintaining the library :) |
GitHub Actions is having a bad day and has queued the CodeQL action for 35 minutes (and counting). Given that previous commits passed the CI ✅ And that main is also green, I'm going to merge as-is. |
Follow up to #171
cc @Zerpet
cc @jxsl13 since it may be interesting