Skip to content

fix: nil error SEGFAULT#42

Merged
zfields merged 3 commits intomasterfrom
zak-segfault
May 7, 2025
Merged

fix: nil error SEGFAULT#42
zfields merged 3 commits intomasterfrom
zak-segfault

Conversation

@zfields
Copy link
Copy Markdown
Contributor

@zfields zfields commented May 7, 2025

  • Performs nil check on error before dereference
  • Lowercases request type value in schema file path
  • Provides launch.json for debugging notecard and notehub CLIs
  • Improves error message readability for unknown request.

@zfields zfields requested review from Bucknalla and Copilot May 7, 2025 00:33
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 addresses a SEGFAULT issue by adding a nil check before an error is dereferenced, improves error message clarity for unknown requests, and adds a launch.json file for CLI debugging.

  • Adds a nil check in formatErrorMessage to prevent a nil-pointer dereference.
  • Updates resolveSchemaError to improve error message readability and to handle unknown request types by checking file existence.
Files not reviewed (1)
  • .vscode/launch.json: Language not supported

Comment thread notecard/validate.go Outdated
zfields added 2 commits May 6, 2025 21:29
Also, improves error message readability for unknown request
Copy link
Copy Markdown
Collaborator

@Bucknalla Bucknalla left a comment

Choose a reason for hiding this comment

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

LGTM

Comment thread notecard/validate.go Outdated
Comment thread notecard/validate.go Outdated
Notecard API is case sensitive
@zfields zfields merged commit 2f3cc23 into master May 7, 2025
1 check passed
@zfields zfields deleted the zak-segfault branch May 7, 2025 14:01
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