]> git.ipfire.org Git - thirdparty/coreutils.git/commit
fold: use fread instead of getline
authorCollin Funk <collin.funk1@gmail.com>
Sun, 24 Aug 2025 19:05:41 +0000 (12:05 -0700)
committerCollin Funk <collin.funk1@gmail.com>
Sun, 24 Aug 2025 20:42:40 +0000 (13:42 -0700)
commitfb9016d50505b2cb66179dd526249063bc393846
treef8ffee7a35d88e19afe62fbefeee3a5fd79a7fc1
parent4bfcf62f74b38d762ee06ceef582c326023635a9
fold: use fread instead of getline

* src/fold.c: Include ioblksize.h.
(fold_file): Use two IO_BUFSIZE-sized buffers. Use fread instead of
getline. Check for if we reached the end of file.
src/fold.c