Skip to content

RDKEMW-13271: Fix for crash when calling readEDID in STB#18

Open
preeja33 wants to merge 4 commits into
developfrom
feature/RDKEMW-13271_2
Open

RDKEMW-13271: Fix for crash when calling readEDID in STB#18
preeja33 wants to merge 4 commits into
developfrom
feature/RDKEMW-13271_2

Conversation

@preeja33

@preeja33 preeja33 commented Apr 2, 2026

Copy link
Copy Markdown
Contributor

Reason for change: Fix for crash when calling readEDID in STB
Test Procedure : compiled and verified
Version : Minor
Risks: Low

@preeja33
preeja33 requested a review from a team as a code owner April 2, 2026 13:19
Copilot AI review requested due to automatic review settings April 2, 2026 13:19

Copilot AI 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.

Pull request overview

Fix intended to prevent a crash when calling ReadEDID on STB by broadening exception handling around EDID retrieval/encoding.

Changes:

  • Changed ReadEDID exception handler from catch (const device::Exception& err) to catch (...).

Comment thread plugin/AVInputImplementation.cpp Outdated
Copilot AI review requested due to automatic review settings April 2, 2026 13:27

Copilot AI 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.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 3 comments.

Comment thread plugin/AVInputImplementation.cpp
Comment thread plugin/AVInputImplementation.cpp
Comment thread plugin/AVInputImplementation.cpp
Copilot AI review requested due to automatic review settings April 6, 2026 09:37

Copilot AI 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.

Pull request overview

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

Comment on lines 601 to 603
int id;

LOGERR("ReadEDID: In predebug");
try {

Copilot AI Apr 6, 2026

Copy link

Choose a reason for hiding this comment

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

LOGERR("ReadEDID: In predebug") looks like a temporary debug trace and is logged at error level even on the success path. This will pollute error logs and can confuse monitoring/operations; please remove it or downgrade to an appropriate non-error log level (and same for the later "edidvec predebug" log).

Copilot uses AI. Check for mistakes.

vector<uint8_t> edidVec({ 'u', 'n', 'k', 'n', 'o', 'w', 'n' });

LOGERR("ReadEDID: edidvec predebug");

Copilot AI Apr 6, 2026

Copy link

Choose a reason for hiding this comment

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

LOGERR("ReadEDID: edidvec predebug") is emitted unconditionally on the success path at error level and appears to be leftover debugging. Consider removing it or changing to a debug/info-level log gated behind a build/runtime flag.

Suggested change
LOGERR("ReadEDID: edidvec predebug");

Copilot uses AI. Check for mistakes.
Copilot AI review requested due to automatic review settings April 6, 2026 09:54

Copilot AI 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.

Pull request overview

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

Comment on lines +612 to 616
LOGERR("ReadEDID: edidvec predebug");
try {
vector<uint8_t> edidVec2;
LOGERR("getEDIDBytesInfo predebug");
device::HdmiInput::getInstance().getEDIDBytesInfo(id, edidVec2);

Copilot AI Apr 6, 2026

Copy link

Choose a reason for hiding this comment

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

These LOGERR("...predebug") statements around getEDIDBytesInfo() will produce ERROR-level noise in normal operation and the messages are not actionable. Recommend removing them (or converting to debug-level logs with useful context like portId/id only when needed).

Copilot uses AI. Check for mistakes.
success = false;
return Core::ERROR_GENERAL;
} catch (...) {
LOGERR("ReadEDID: Caught exception");

Copilot AI Apr 6, 2026

Copy link

Choose a reason for hiding this comment

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

In the catch (...) block, the log message is very generic. Since what() is not available here, consider at least logging the portId/id so operational logs can identify which input triggered the failure.

Suggested change
LOGERR("ReadEDID: Caught exception");
LOGERR("ReadEDID: Caught exception for portId: %s, id: %d", portId.c_str(), id);

Copilot uses AI. Check for mistakes.
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