-
Notifications
You must be signed in to change notification settings - Fork 85
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
Replying to a query with a closed session should not yield an UB. #476
Comments
Is this really a good idea ? Do we really need to hold on session while query is still alive ? I.e. are we supposed to ignore z_close() and wait till all queries are resolved ? |
I mean the session may outlive the The reverse is just a UB/segfault if the query is used to send a reply after It feels like the former is better than the latter but it's open to discussion. |
After internal discussion, we'll keep the session as a reference, but we should make sure that replying to a closed session do not result in a UB. |
Describe the feature
As we removed refcounting on queries, we no longer have the issue of cross-referencing rc that prevented us from refcounting the query session pointer.
A session rc is preferable to a pointer, especially if the query is used out of the callback context and more in line with the rest of the codebase.
The text was updated successfully, but these errors were encountered: