aboutsummaryrefslogtreecommitdiffstats
path: root/tests/misc/write-errors.sh
diff options
context:
space:
mode:
authorPádraig Brady <P@draigBrady.com>2025-10-22 13:53:46 +0100
committerPádraig Brady <P@draigBrady.com>2025-10-22 15:53:06 +0100
commit5971f450b5abffd5a335a8937d6d588431137594 (patch)
tree02691c5bdd81210050ca0ca5ae06cfbb239d11fc /tests/misc/write-errors.sh
parentinstall: prefer posix_spawnp to fork and execlp (diff)
downloadcoreutils-5971f450b5abffd5a335a8937d6d588431137594.tar.gz
coreutils-5971f450b5abffd5a335a8937d6d588431137594.zip
numfmt: promptly diagnose write errors
* src/numfmt.c (process line): Inspect the stdio error state when outputting each line so that we don't have to check each output function but do eventually exit upon write error, while also remaining buffered. (main): Also check when outputting a header for the edge case of very long headers. * tests/misc/write-errors.sh: Enable the numfmt test case. * NEWS: Mention the improvement, and reorganize all numfmt improvements.
Diffstat (limited to 'tests/misc/write-errors.sh')
-rwxr-xr-xtests/misc/write-errors.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/misc/write-errors.sh b/tests/misc/write-errors.sh
index b30f4f6bd..782ccae5a 100755
--- a/tests/misc/write-errors.sh
+++ b/tests/misc/write-errors.sh
@@ -41,7 +41,7 @@ fold --version; yes | tr -d '\\n' | fold
head -z -n-1 /dev/zero
join -a 1 -z /dev/zero /dev/null
# TODO: nl --version; yes | nl
-# TODO: numfmt --version; yes 1 | numfmt
+numfmt --version; yes 1 | numfmt
od -v /dev/zero
paste /dev/zero
# TODO: pr /dev/zero