fix: fix potential use after free when removing Connections from ConnManager#7787
Merged
fix: fix potential use after free when removing Connections from ConnManager#7787
Conversation
823bc02 to
2fad90b
Compare
2fad90b to
6630461
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #7787 +/- ##
==========================================
- Coverage 84.78% 84.78% -0.01%
==========================================
Files 351 351
Lines 54798 54800 +2
Branches 14764 14764
==========================================
- Hits 46462 46461 -1
- Misses 8137 8140 +3
Partials 199 199
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
GuyAv46
approved these changes
Dec 15, 2025
Contributor
|
Successfully created backport PR for |
github-merge-queue bot
pushed a commit
that referenced
this pull request
Dec 15, 2025
…m ConnManager (#7796) fix: fix potential use after free when removing Connections from ConnManager (#7787) fix: fix potential use after free (cherry picked from commit d80e74c) Co-authored-by: Joan Fontanals <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Describe the changes in the pull request
In the MRConnPool_Free we should set the connection pointed from the callbackCtx to NULL to avoid accessing freed data.
Note
Clear
conn->conn->datainMRConnPool_Freebefore freeing connections to prevent callbacks from accessing freed memory.Written by Cursor Bugbot for commit 6630461. This will update automatically on new commits. Configure here.