Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sys/iolist: add helper functions #18044

Merged
merged 5 commits into from
May 3, 2022
Merged

Conversation

benpicco
Copy link
Contributor

@benpicco benpicco commented May 2, 2022

Contribution description

So I stopped worrying and learned to love iolist, but I noticed some useful functions could be needed.
This adds:

  • iolist_to_buffer() to copy the iolist to a buffer
  • vfs_write_iol() to write the iolist to a file

Testing procedure

gnrc_sock_udp has been modified to make use of iolist_to_buffer(). With this, tests/gnrc_sock_udp still passes.

Issues/PRs references

@benpicco benpicco requested a review from kaspar030 May 2, 2022 21:13
@github-actions github-actions bot added Area: network Area: Networking Area: sys Area: System labels May 2, 2022
@kaspar030 kaspar030 added the CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR label May 2, 2022
Copy link
Contributor

@kaspar030 kaspar030 left a comment

Choose a reason for hiding this comment

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

ACK.

This avoids a conflict with the functions from unistd.h
@github-actions github-actions bot added the Area: tests Area: tests and testing framework label May 2, 2022
@benpicco benpicco merged commit 8401ee7 into RIOT-OS:master May 3, 2022
@benpicco benpicco deleted the iolist-helper branch May 3, 2022 08:12
@chrysn chrysn added this to the Release 2022.07 milestone Aug 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: network Area: Networking Area: sys Area: System Area: tests Area: tests and testing framework CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants