Skip to content

Validate sensor calibration files#528

Merged
Eirenliel merged 2 commits into
mainfrom
fix/configuration
May 30, 2026
Merged

Validate sensor calibration files#528
Eirenliel merged 2 commits into
mainfrom
fix/configuration

Conversation

@unlogisch04
Copy link
Copy Markdown
Contributor

change FS I/O
Add stricter validation when loading sensor calibrations: skip files with unexpected size, warn and skip if the read bytes don't match the expected struct size, and validate the sensorConfig.type value before using it. Initialize SensorConfig to zeros prior to reading. Change FSHelper read/write signatures to return size_t (bytes read/written) instead of bool to accurately reflect I/O results.
Used copilot to help

Add stricter validation when loading sensor calibrations: skip files with unexpected size, warn and skip if the read bytes don't match the expected struct size, and validate the sensorConfig.type value before using it. Initialize SensorConfig to zeros prior to reading. Change FSHelper read/write signatures to return size_t (bytes read/written) instead of bool to accurately reflect I/O results.
Used copilot to help
@unlogisch04 unlogisch04 requested a review from Eirenliel as a code owner May 28, 2026 23:40
@Eirenliel Eirenliel requested a review from gorbit99 May 30, 2026 18:34
@Eirenliel Eirenliel merged commit cc52f97 into main May 30, 2026
2 checks passed
@Eirenliel Eirenliel deleted the fix/configuration branch May 30, 2026 18:35
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.

2 participants