Skip to content

RDKCOM-5642: RDKBDEV-3499, RDKBACCL-1878 Adding condition check for Base MAC address - #43

Open
manigandanj wants to merge 1 commit into
rdkcentral:mainfrom
manigandanj:AddConditionCheck
Open

manigandanj wants to merge 1 commit into
rdkcentral:mainfrom
manigandanj:AddConditionCheck

Conversation

@manigandanj

Copy link
Copy Markdown

Reason for change: To avoid addition of trailing MAC address without base MAC address
Test procedure: Sanity
Risks: Low

Copilot AI lite review requested due to automatic review settings September 8, 2026 09:13
@manigandanj
manigandanj requested a review from a team as a code owner September 8, 2026 09:13

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

The change is small, targeted, and reduces the likelihood of generating an invalid derived MAC when the base MAC is missing.

Pull request overview

Adds a guard in EthLink_GetMacAddr() to fail fast when the base MAC address lookup returns an empty string, preventing computation of an offset MAC from missing base data.

Changes:

  • Added an explicit empty-string check on the base MAC address returned by DmlEthGetParamValues().
  • Logs an error and returns failure when the base MAC address is empty.
File summaries
File Description
source/TR-181/middle_layer_src/ethernet_apis.c Adds a condition to reject empty base MAC address values before offset/formatting logic.
Review details
  • Files reviewed: 1/1 changed files
  • Comments generated: 1
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread source/TR-181/middle_layer_src/ethernet_apis.c
@manigandanj manigandanj changed the title RDKBACCL-1878: Adding condition check for Base MAC address RDKBDEV-3499, RDKBACCL-1878: Adding condition check for Base MAC address Sep 8, 2026
Reason for change: To avoid addition of trailing MAC address without base
MAC address
Test procedure: Sanity
Risks: Low

Signed-off-by: Manigandan Gopalakrishnan <Manigandan_Gopalakrishnan@comcast.com>
@pradeeptakdas pradeeptakdas changed the title RDKBDEV-3499, RDKBACCL-1878: Adding condition check for Base MAC address RDKCOM-5642: RDKBDEV-3499, RDKBACCL-1878 Adding condition check for Base MAC address Sep 9, 2026

@S-Parthiban-Selvaraj S-Parthiban-Selvaraj left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Will be consumed in the next Wan components release

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.

4 participants