Skip to content

ENT-11346: Added BufferAppendFileContent() - #295

Merged
larsewi merged 1 commit into
NorthernTechHQ:masterfrom
aleksandrychev:ENT-11346
Aug 20, 2026
Merged

ENT-11346: Added BufferAppendFileContent()#295
larsewi merged 1 commit into
NorthernTechHQ:masterfrom
aleksandrychev:ENT-11346

Conversation

@aleksandrychev

Copy link
Copy Markdown
Contributor

Reads from a file descriptor until end of file and appends everything to the buffer. cf-reactor needs this to collect the output of the cfbs commands it spawns, and had its own copy of the loop.

Ticket: ENT-11346
Changelog: None

@mender-test-bot

Copy link
Copy Markdown

There was an error running your pipeline, see logs for details.

@aleksandrychev

Copy link
Copy Markdown
Contributor Author

@larsewi please review

@larsewi larsewi 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.

Change this to a do-while-loop and use ((size_t) n_read < sizeof(bytes)) as the loop condition.

Reads from a file descriptor until end of file and appends everything to
the buffer. cf-reactor needs this to collect the output of the cfbs
commands it spawns, and had its own copy of the loop.

Ticket: ENT-11346
Changelog: None
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@mender-test-bot

Copy link
Copy Markdown

There was an error running your pipeline, see logs for details.

@aleksandrychev
aleksandrychev requested a review from larsewi August 20, 2026 07:53

@larsewi larsewi 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.

Looks great 🚀

@aleksandrychev

Copy link
Copy Markdown
Contributor Author

@larsewi please merge, I don't have access

@larsewi
larsewi merged commit 3c21479 into NorthernTechHQ:master Aug 20, 2026
13 of 21 checks passed
@larsewi

larsewi commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

Please update the submodule in core repo, or wait for the github workflow to do it. I think it runs once a day.

@larsewi

larsewi commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

Please update the submodule in core repo, or wait for the github workflow to do it. I think it runs once a day.

I did it here cfengine/core#6329

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