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

fix: two segmentation faults in cluster::guild_edit_member and cluster::tick_timers/cluster::shutdown #1326

Merged
merged 2 commits into from
Nov 9, 2024

Conversation

KTuff
Copy link

@KTuff KTuff commented Nov 8, 2024

cluster::guild_edit_member accesses invalid memory in its callback if the guild_member object is deallocated before the post_rest makes a call to the callback. Capturing the object as copy fixes this issue.

cluster::shutdown does not clear the next_timer map which causes segfaults in cluster::tick_timers if the timers are not removed before shutdown. Clearing the map after all timers are deleted resolves this.

Code change checklist

  • I have ensured that all methods and functions are fully documented using doxygen style comments.
  • My code follows the coding style guide.
  • I tested that my change works before raising the PR.
  • I have ensured that I did not break any existing API calls.
  • I have not built my pull request using AI, a static analysis tool or similar without any human oversight.

@CLAassistant
Copy link

CLAassistant commented Nov 8, 2024

CLA assistant check
All committers have signed the CLA.

Copy link

netlify bot commented Nov 8, 2024

Deploy Preview for dpp-dev ready!

Name Link
🔨 Latest commit 11a42a3
🔍 Latest deploy log https://app.netlify.com/sites/dpp-dev/deploys/672e892154b4ae0008d08122
😎 Deploy Preview https://deploy-preview-1326--dpp-dev.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@github-actions github-actions bot added the code Improvements or additions to code. label Nov 8, 2024
Copy link
Contributor

@braindigitalis braindigitalis left a comment

Choose a reason for hiding this comment

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

looks good to me, thanks for the contribution!

@braindigitalis braindigitalis added the bug Something isn't working label Nov 9, 2024
@braindigitalis braindigitalis merged commit 6d8f746 into brainboxdotcc:dev Nov 9, 2024
51 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working code Improvements or additions to code.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants