Skip to content

fix: handle segfault on missing input data#51

Merged
Bucknalla merged 1 commit intomasterfrom
alex-fix-card.binary.put-segfault
Aug 7, 2025
Merged

fix: handle segfault on missing input data#51
Bucknalla merged 1 commit intomasterfrom
alex-fix-card.binary.put-segfault

Conversation

@Bucknalla
Copy link
Copy Markdown
Collaborator

No description provided.

@Bucknalla Bucknalla requested a review from Copilot August 7, 2025 09:17
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR fixes a potential segfault by adding a nil check for the Payload field before dereferencing it in the card.binary.put request handling logic.

  • Adds validation to ensure req.Payload is not nil before attempting to dereference it
  • Returns a descriptive error message when payload data is missing

@Bucknalla Bucknalla requested a review from zfields August 7, 2025 09:25
@zfields
Copy link
Copy Markdown
Contributor

zfields commented Aug 7, 2025

That diff really made the simple addition of an if look much more involved. 😂

@Bucknalla Bucknalla merged commit fcc2e2e into master Aug 7, 2025
1 check passed
@Bucknalla Bucknalla deleted the alex-fix-card.binary.put-segfault branch August 7, 2025 14:05
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