Skip to content

Feature/rdk 60236 comma#188

Open
Abhinavpv28 wants to merge 76 commits intodevelopfrom
feature/RDK-60236_Comma
Open

Feature/rdk 60236 comma#188
Abhinavpv28 wants to merge 76 commits intodevelopfrom
feature/RDK-60236_Comma

Conversation

@Abhinavpv28
Copy link
Copy Markdown
Contributor

No description provided.

Copilot AI review requested due to automatic review settings May 3, 2026 11:37
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 3, 2026

Code Coverage Summary

                               Total:|83.4%   6014|97.1%  1564|    -      0

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

Copilot reviewed 6 out of 8 changed files in this pull request and generated 4 comments.

Comment thread src/rrdEventProcess.c
Comment thread src/rrdEventProcess.c
Comment thread src/rrdEventProcess.c
Comment thread src/rrdInterface.c
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 3, 2026 11:46
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
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

Copilot reviewed 6 out of 8 changed files in this pull request and generated 4 comments.

Comments suppressed due to low confidence (1)

src/unittest/rrdUnitTestRunner.cpp:3777

  • This test builds a data_buf rbuf without zero-initializing it (fields like appendMode, dsEvent are left uninitialized) and allocates rbuf.mdata, rbuf.suffix, and msgHdr.mbody without freeing them after RRDEventThreadFunc() returns. Since the EVENT_MSG path does not free the received buffer, this can cause leaks and test flakiness depending on the garbage values in the struct. Initialize rbuf (e.g., data_buf rbuf = {}; / RRD_data_buff_init) and explicitly free msgHdr.mbody and any owned allocations after the call (or adjust the code under test to own/free them consistently).
    data_buf rbuf;
    rbuf.mtype = EVENT_MSG;
    rbuf.mdata = strdup("Test");
    rbuf.inDynamic = true;
    rbuf.jsonPath = nullptr;
    rbuf.suffix = strdup("_search_b675-657-556-656");
    ASSERT_NE(rbuf.suffix, nullptr);
    msgRRDHdr msgHdr;
    msgHdr.mbody = malloc(sizeof(data_buf));
    ASSERT_NE(msgHdr.mbody, nullptr);
    memcpy(msgHdr.mbody, &rbuf, sizeof(data_buf));
    ASSERT_NE(msgsnd(msqid, &msgHdr, sizeof(void *), 0), -1);

Comment thread src/rrdEventProcess.c
Comment thread src/rrdEventProcess.c
Comment thread src/rrdJsonParser.c
Comment thread src/unittest/rrdUnitTestRunner.cpp Outdated
Copilot AI review requested due to automatic review settings May 3, 2026 12:06
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 3, 2026

Code Coverage Summary

                               Total:|83.4%   6014|97.1%  1564|    -      0

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

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

Comments suppressed due to low confidence (1)

src/unittest/rrdUnitTestRunner.cpp:3775

  • This test constructs a data_buf without zero-initializing it (leaving fields like appendMode/dsEvent indeterminate) and allocates rbuf.suffix without a clear ownership/freeing path in the test. Please initialize the struct (e.g., value-initialize or call RRD_data_buff_init and then set the fields you need) and ensure any heap allocations made by the test are released (or assert that the code under test takes ownership and frees them).
    data_buf rbuf;
    rbuf.mtype = EVENT_MSG;
    rbuf.mdata = strdup("Test");
    rbuf.inDynamic = true;
    rbuf.jsonPath = nullptr;
    rbuf.suffix = strdup("_search_b675-657-556-656");
    msgRRDHdr msgHdr;
    msgHdr.mbody = malloc(sizeof(data_buf));
    ASSERT_NE(msgHdr.mbody, nullptr);
    memcpy(msgHdr.mbody, &rbuf, sizeof(data_buf));

Comment thread src/rrdEventProcess.c
Comment thread src/rrdInterface.c
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 4, 2026 13:44
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 4, 2026

Code Coverage Summary

                               Total:|83.3%   6022|97.1%  1564|    -      0

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 4, 2026

Code Coverage Summary

                               Total:|83.3%   6022|97.1%  1564|    -      0

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

Copilot reviewed 6 out of 8 changed files in this pull request and generated 4 comments.

Comment thread src/rrdInterface.c
Comment thread src/rrdEventProcess.c
Comment thread src/rrdEventProcess.c
Comment thread src/unittest/rrdUnitTestRunner.cpp
Copilot AI review requested due to automatic review settings May 4, 2026 14:44
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 4, 2026

Code Coverage Summary

                               Total:|83.3%   6022|97.1%  1564|    -      0

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 4, 2026

Code Coverage Summary

                               Total:|83.3%   6022|97.1%  1564|    -      0

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 4, 2026

Code Coverage Summary

                               Total:|83.3%   6022|97.1%  1564|    -      0

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.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

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