Skip to content

nolibc: Add fread() and fseek()

Daniel Palmer lkml 2 versions – New

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest3 patches 0 repliesNew
  2. v12 patches 12 repliesSuperseded

Changes in v2 from the cover letter

- A few style clean ups in fread() requested by Thomas.
- Added a basic test that exercises the new functions. This isn't a complete POSIX testsuite, just a very basic smoke test. I couldn't think of proper error numbers for different failure cases (Suggested by Thomas), any ideas appreciated.

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3tools/nolibc: Add fread() to stdio.htools/include/nolibc/stdio.h+33 -10 replies
2/3tools/nolibc: Add fseek() to stdio.htools/include/nolibc/stdio.h+19 -00 replies
3/3tools/nolibc: Add a simple test for writing to a FILE and reading it backtools/testing/selftests/nolibc/nolibc-test.c+53 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH v2 0/3] nolibc: Add fread() and fseek()

v1 blurb:

Using nolibc on nommu 68000, something I'm trying to build[0] wanted fread() and fseek() so I added them, they seem to work so I'm sharing them. Not sure if I need to add tests or something? Maybe there is a reason these weren't implemented in the first place...

0 - https://github.com/FrenkelS/Doom8088ST/issues/21

Changelog:
v2:
- A few style clean ups in fread() requested by Thomas.
- Added a basic test that exercises the new functions. This isn't a complete POSIX testsuite, just a very basic smoke test. I couldn't think of proper error numbers for different failure cases (Suggested by Thomas), any ideas appreciated.

Daniel Palmer (3):
tools/nolibc: Add fread() to stdio.h
tools/nolibc: Add fseek() to stdio.h
tools/nolibc: Add a simple test for writing to a FILE and reading it
back

 tools/include/nolibc/stdio.h                 | 53 +++++++++++++++++++-
 tools/testing/selftests/nolibc/nolibc-test.c | 53 ++++++++++++++++++++
 2 files changed, 105 insertions(+), 1 deletion(-)
Signature · 1 line
2.51.0