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

Mitigate two potential nil pointer dereference issues. #5102

Closed
wants to merge 2 commits into from

Conversation

x676f64
Copy link

@x676f64 x676f64 commented Apr 24, 2024

Proposed changes

These changes patch two cases where a nil pointer dereference can occur.

Checklist

  • [X ] Pull request is created against the dev branch
  • All checks passed (lint, unit/integration/regression tests etc.) with my changes
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)

@GeorginaReeder
Copy link

Thanks so much for your contribution @x676f64 , we appreciate it! :)

@tarunKoyalwar
Copy link
Member

@x676f64 , thanks for contributing but there doesn't seem to be any nil pointer dereference errors or a chance of it in based on changes

In golang Nil Pointer dereference only occurs when pointers are used and that is not the case in StackMonitor and for defer unlock in callback , mutex was used at that place because the variable was updated , invoking callbacks doesn't require syncronization

closing this pr for now , feel free to create new pr if you encountered a panic

@tarunKoyalwar tarunKoyalwar removed their request for review May 6, 2024 16:16
Copy link
Member

@tarunKoyalwar tarunKoyalwar left a comment

Choose a reason for hiding this comment

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

closing since there doesn't seem to be issue in code

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.

3 participants