Skip to content

RDKB-64593 : Coverity issues in ccsp-common-library phase 2#110

Merged
snayak002c merged 1 commit into
developfrom
feature/RDKB-64593
Apr 24, 2026
Merged

RDKB-64593 : Coverity issues in ccsp-common-library phase 2#110
snayak002c merged 1 commit into
developfrom
feature/RDKB-64593

Conversation

@ksures101
Copy link
Copy Markdown
Contributor

Reason for change: To address high impact coverity issues
Test Procedure: There should not be any coverity issues mentioned in the ticket
Risks: None

Signed-off-by: kavyachowdahalli_suresh@comcast.com

Reason for change: To address high impact coverity issues
Test Procedure: There should not be any coverity issues mentioned in the ticket
Risks: None

Signed-off-by: kavyachowdahalli_suresh@comcast.com
Copilot AI review requested due to automatic review settings April 24, 2026 06:03
@ksures101 ksures101 requested review from a team as code owners April 24, 2026 06:03
Copy link
Copy Markdown
Contributor

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 high-impact Coverity findings in ccsp-common-library by tightening control-flow to avoid unsafe operations and ensure allocated resources are released on error paths.

Changes:

  • Prevent potential out-of-bounds/overflow behavior in BspTemplateArchiveSaveToFile() by stopping the write loop when sprintf_s fails.
  • Fix resource leaks in SetParamValueHelper() by routing error returns through a cleanup label that frees allocated strings.
  • Fix resource leaks in SlapDslhParamtoIsParameterReadOnly() by ensuring allocated strings are freed before returning the read-only result.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
source/cosa/utilities/bsp_eng/bspeng_archive_co_process.c Stops comma-separated serialization loop on sprintf_s failure to avoid unsafe subsequent operations.
source/cosa/package/slap/services/dslh/SlapDslhParamTree/slap_dslh_paramto_access.c Uses goto cleanup on error/return paths to consistently release allocated resources and resolve Coverity leak reports.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@snayak002c snayak002c merged commit bf41b3b into develop Apr 24, 2026
14 checks passed
@github-actions github-actions Bot locked and limited conversation to collaborators Apr 24, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants