]> git.ipfire.org Git - thirdparty/coreutils.git/commit
fmt: promptly diagnose write errors
authorPádraig Brady <P@draigBrady.com>
Wed, 22 Oct 2025 15:11:53 +0000 (16:11 +0100)
committerPádraig Brady <P@draigBrady.com>
Wed, 22 Oct 2025 15:18:06 +0000 (16:18 +0100)
commitc12a2ecb53e9c141e705a2e4645de5201237a1f6
tree1a6d6527dfd46154be0fdcbffa4303579a5c6827
parent5971f450b5abffd5a335a8937d6d588431137594
fmt: promptly diagnose write errors

* NEWS: Mention the improvement.
* src/fmt.c (put_line): Exit if any error writing line.
(flush_paragraph): Exit if any error writing buffer.
* tests/misc/write-errors.sh: Enable the (flush_paragraph) test case,
and add another to check the put_line() case.
NEWS
src/fmt.c
tests/misc/write-errors.sh