Skip to content

Conversation

@sosthene-nitrokey
Copy link
Contributor

These APIs will be useful for a trussed streaming API

@nickray
Copy link
Member

nickray commented Apr 6, 2023

Do you envision some kind of read_to_end method that allows "just" reading a file that's bigger than our interchange buffer? This would call read_chunk multiple times, possibly failing early. I think that would be very ergonomic for an app, however it might be hacky with the multiple syscalls involved.

@sosthene-nitrokey
Copy link
Contributor Author

sosthene-nitrokey commented Apr 6, 2023

This doesn't make sense in littlefs2 I think, as in that case you can already use write_all and read_to_end.

I do add such a util in the trussed itself: https://github.com/Nitrokey/trussed/pull/18/files#diff-23af5356f6001cd3993cd3c801fb7716ea02d1e504081b9fb569332db6107e80R12

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