2025-11-10  Pádraig Brady  <P@draigBrady.com>

	version 9.9
	* NEWS: Record release date.

2025-11-10  Collin Funk  <collin.funk1@gmail.com>

	nice: clamp the niceness correctly on GNU/Hurd
	* NEWS: Mention the bug fix.
	* src/nice.c (MIN_ADJUSTMENT): Set to 0 on the Hurd with glibc ≤ 2.42.
	(MAX_ADJUSTMENT): Set to (2 * NZERO - 2) on the Hurd with glibc ≤ 2.42.
	(main): Clamp the niceness to be greater or equal to MIN_ADJUSTMENT and
	less than or equal to MAX_ADJUSTMENT.
	* tests/nice/nice.sh: Add some tests for the Hurd's ranges.

2025-11-08  Collin Funk  <collin.funk1@gmail.com>

	tests: tail: avoid a test failure on GNU/Hurd
	* tests/tail/tail-c.sh: Allow 'tail -c 4096 /dev/urandom' to run forever
	on GNU/Hurd since lseek fails with ESPIPE.

2025-11-08  Pádraig Brady  <P@draigBrady.com>

	chcon: fix memory leak in error path
	* src/chcon.c (change_file_context): If compute_context_from_mask fails,
	free the previously allocated file_context.
	Fixes https://bugs.gnu.org/79780

	tests: avoid false failure due to small timeout
	* tests/tail/tail-c.sh: Tests that fail after a timeout
	should use as least 10s to avoid intermittent failures
	on slow/loaded hosts.

2025-11-08  Collin Funk  <collin.funk1@gmail.com>

	build: update gnulib submodule to latest

2025-11-07  Pádraig Brady  <P@draigBrady.com>

	install: fix crash with --strip and large $PATH on ppc and sparc
	* gnulib: Update to the latest gnulib to pull in the fix
	(v1.0-2406-g89f63027de) to allocate the $PATH processing memory
	before the vfork call, which is required on ppc and sparc.
	* tests/install/basic-1.sh: Ensure posix_spawnp() suports a large $PATH,
	which needs careful handling with vfork() as detailed in gnulib.

2025-11-07  Pádraig Brady  <P@draigBrady.com>

	doc: cksum: clarify support of --text and --binary
	Make the documentation more accurate following v9.3-80-g5e1e0993b

	* doc/coreutils.texi (cksum common options): State that --text and
	--binary are actually supported, but only to support emulation
	of the legacy utils.

2025-11-07  Collin Funk  <collin.funk1@gmail.com>

	tests: wc: protect against a hang on GNU/Hurd
	Reported by Bruno Haible in
	<https://lists.gnu.org/r/coreutils/2025-11/msg00051.html>.

	* tests/wc/wc-total.sh: Skip a test that would exhaust memory on
	GNU/Hurd.

2025-11-05  Pádraig Brady  <P@draigBrady.com>

	gnulib: update to latest
	* NEWS: Mention the nproc build fix for older Android.

2025-11-05  Collin Funk  <collin.funk1@gmail.com>

	doc: mention nanosecond decimal points with --iso-8601=ns
	Many people are used to seeing ISO 8601 dates using a period separating
	seconds and nanoseconds. This behavior seems to be worth documenting
	given the bug reports:
	https://bugs.gnu.org/63119
	https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1118970

	* doc/coreutils.texi (Options for date): Mention that
	'date --iso-8601=ns' uses a comma as a separator, following the
	preference of ISO 8601. Give an example of how to get an ISO 8601 date
	with a period separator.

2025-11-04  Pádraig Brady  <P@draigBrady.com>

	maint: adjust lseek_copy to handle non zero offsets
	* src/copy-file-data.c (lseek_copy): hole_start is initialized
	only when ext_start == ipos.
	(infer_scantype): Update the hole_start initialization to
	the more logically correct POS, even though that init
	is only needed to suppress a -Wmaybe-uninitialized warning.
	Note gcc 15.2 at least doesn't seem to need that suppression.

2025-11-04  Bernhard Voelker  <mail@bernhard-voelker.de>

	tests: avoid skipping of LD_PRELOAD based df tests
	It was seen that gnulib's read_file_system_list may use fopen instead
	of open.  Adjust the df(1) tests to replace both library functions.

	* tests/df/no-mtab-status.sh: Change the shared library code invoked
	via LD_PRELOAD to override both fopen and open.  While at it, perform
	varargs processing only when path is not "/proc/self/mountinfo".
	* tests/df/skip-duplicates.sh: Likewise.

2025-11-04  Bernhard Voelker  <mail@bernhard-voelker.de>

	tests: avoid skipping by fixing build of shared libraries
	Two df(1) tests were skipped (since commit ee367bd38dac), because
	the build of the shared library in those tests failed.

	  + gcc -Wall -shared --std=gnu99 -fPIC -O2 k.c -o k.so -ldl
	  k.c: In function 'open':
	  k.c:37:7: error: implicit declaration of function 'streq'; did you \
	  mean 'strsep'? [-Wimplicit-function-declaration]
	     37 |   if (streq (path, "/proc/self/mountinfo"))
	        |       ^~~~~
	        |       strsep

	Gnulib streq is not available in the tests.

	* tests/df/no-mtab-status.sh: Replace "streq" by "0==strcmp" in the
	shared library source.
	* tests/df/skip-duplicates.sh: Likewise.

2025-11-04  Collin Funk  <collin.funk1@gmail.com>

	tests: date: check that write errors are promptly diagnosed
	This improvement is due to changes to Gnulib's fprintftime module.

	* NEWS: Mention the improvement.
	* src/getlimits.c (OFF64_T_MAX, OFF64_T_MIN): New macros.
	(main): Print them.
	* tests/misc/write-errors.sh: Call getlimits_. Add a date invocation.

2025-11-03  Paul Eggert  <eggert@cs.ucla.edu>

	doc: squashfs issue to be squashed in Linux 6.18

2025-11-03  Pádraig Brady  <P@draigBrady.com>

	tests: truncate: ensure negative args not parsed as options
	* tests/truncate/truncate-parameters.sh: Add a test case.

	date: avoid a duplicated write error diagnotic
	* src/show-date.c (show_date): Only show the fprintftime() diagnostic
	if a further diagnostic will not be shown.

	date: translate/clarify recent error message
	* src/show-date.c (show_date): Flagged by syntax-check.

	date: promptly diagnose write errors with --file
	* src/date.c (batch_convert): Check error state of stdout
	after each date is processed.
	* tests/misc/write-errors.sh: Add a test case.

2025-11-02  Collin Funk  <collin.funk1@gmail.com>

	tests: stty: filter out ispeed and ospeed from boolean options
	* tests/stty/stty-pairs.sh: Also ignore lines starting with ispeed and
	ospeed.
	* tests/stty/stty.sh: Likewise.
	Reported by Bernhard Voelker.

2025-11-02  Paul Eggert  <eggert@cs.ucla.edu>

	date: diagnose fprintftime failure
	* src/show-date.c (show_date): Diagnose fprintftime failure,
	as it need not be an output error.

	pr: improve nstrftime failure check
	* src/pr.c (init_header): Do not report an nstrftime EOVERFLOW
	error as memory exhaustion.  Instead, output the time as an
	integer.  Also, work even if nstrftime (nullptr, SIZE_MAX, ...)
	would return PTRDIFF_MAX which means adding 1 would overflow..

	ls: better nstrftime failure check
	* src/ls.c (print_long_format): Streamline the checking
	for failure of nstrftime.

	build: update gnulib submodule to latest

2025-11-01  Collin Funk  <collin.funk1@gmail.com>

	tests: date: avoid test failure on NetBSD
	* tests/date/date-tz.sh: Allow date to fail with large values for TZ
	since NetBSD's tzalloc function limits them to 256 bytes.

2025-11-01  Pádraig Brady  <P@draigBrady.com>

	build: reduce explicit dependencies on macOS CoreFoundation
	* src/local.mk: Revert v9.7-322-gc2e1816a5, instead relying
	on the more focused v9.8-79-g532cd66af.  When built with
	--disable-nls on macOS this will result in only some commands
	being linked with INTL_MACOSX_LIBS, thus resulting in env(1)
	at least not setting a __CF_USER_TEXT_ENCODING envirnoment variable.

2025-11-01  Grisha Levit  <grishalevit@gmail.com>

	build: fix macOS build without libintl
	A more precise fix than commit v9.7-322-gc2e1816a5

	* configure.ac (USE_NLS): new AM_CONDITIONAL.
	* src/local.mk: add @INTL_MACOSX_LIBS@ to <prog>_LDADD that need it.

2025-11-01  Bruno Haible  <bruno@clisp.org>

	maint: ln: eliminate a clang -Wformat-extra-args warning
	* src/ln.c (do_link): Don't pass unused arguments to error().
	Don't use "%.0s" to consume a string argument without printing it.

	maint: ls: adjust to gnulib nstrftime changes
	* src/ls.c (align_nstrftime): Change return type to ptrdiff_t.
	(print_long_format): Treat a negative return value from align_nstrftime
	as failure.

2025-11-01  Pádraig Brady  <P@draigBrady.com>

	build: update gnulib submodule to latest
	* gnulib: update to latest

	copy: be more defensive/restrictive with posix_fadvise
	* src/copy-file-data.c (copy_file_data): Only give the
	POSIX_FADV_SEQUENTIAL hint when we _know_ we'll definitely
	use a read/write loop to copy the data.  Also only apply
	the hint to the whole file, as we've seen OpenZFS at least
	special case that.
	(sparse_copy): Update stale comment.

	copy: don't avoid copy-offload upon SEEK_HOLE indicating non-sparse
	* src/copy-file-data.c (infer_scantype): Fall back to a plain copy
	if SEEK_HOLE indicates non-sparse, as zero copy avoids copy offload.
	This was seen with transparently compressed files on OpenZFS.
	* tests/cp/sparse-perf.sh: Add a test case even though it might
	only trigger on compressed file systems that don't support reflink.
	* NEWS: Mention the bug fix.
	Addresses https://github.com/coreutils/coreutils/issues/122

	copy: avoid posix_fadvise bypassing copy offload behavior
	* src/copy-file-data.c (): pass 0 to posix_fadvise to indicate to EOF.
	coreutils 9.8 used OFF_T_MAX instead, which triggered OpenZFS 2.2.2
	at least to synchronously (decompress and) populate the page cache.
	Addresses https://github.com/coreutils/coreutils/issues/122

2025-11-01  Collin Funk  <collin.funk1@gmail.com>

	timeout: use fork and execvp instead of posix_spawn
	* NEWS: Remove timeout from the list of programs that use posix_spawn.
	* bootstrap.conf (gnulib_modules): Remove posix_spawnattr_setsigmask.
	* src/timeout.c: Don't include spawn.h.
	(main): Use fork and execvp instead of posix_spawn.

	This reverts commit dac96ce3e3a2424919fea6a17978b6e91e575d86.

2025-10-31  Pádraig Brady  <P@draigBrady.com>

	doc: NEWS: mention that sort --compress=script needs a shebang
	* NEWS: Mention that we don't fall-back to executing /bin/sh <script>
	for malformed scripts that don't start with #!..., or any executable
	that returns ENOEXEC in general.

2025-10-31  Bruno Haible  <bruno@clisp.org>

	sort: optimize the lookups of the --compress-program
	* src/sort.c (get_resolved_compress_program): New function.
	(pipe_child): Use it instead of calling find_in_given_path each time.

2025-10-31  Collin Funk  <collin.funk1@gmail.com>

	maint: avoid syntax-check failure from previous commit
	* src/sort.c (pipe_child): Use nullptr instead of NULL.

2025-10-30  Bruno Haible  <bruno@clisp.org>

	sort: consistently diagnose access issues to --compress-program
	* bootstrap.conf (gnulib_modules): Add findprog-in.
	* src/sort.c: Include findprog.h.
	(pipe_child): Look up the compress_program in $PATH and report errors
	such as ENOENT or EACCES before invoking posix_spawnp.
	This avoids inconsistency on systems that emulate posix_spawn through
	fork/exec, as they would otherwise treat such a failure as a generic
	failure and fail the sort, rather than continuing without compression.

2025-10-29  Pádraig Brady  <P@draigBrady.com>

	sort: fix silent exit upon SIGPIPE from --compress-program
	* src/sort.c (main): Ignore SIGPIPE so we've more control over
	how we handle for stdout and compression programs.
	(sort_die): Handle EPIPE from stdout and mimic a standard SIGPIPE,
	otherwise reverting to a standard exit(SORT_FAILURE);
	* tests/sort/sort-compress-proc.sh: Add a test case.
	* NEWS: Mention the bug fix.

2025-10-29  Collin Funk  <collin.funk1@gmail.com>

	build: update gnulib submodule to latest

2025-10-28  Pádraig Brady  <P@draigBrady.com>

	tests: fix new date/resolution.sh test on macOS
	* tests/date/resolution.sh: Fix comparison on systems with less than
	nano second reslution, where we use sed to discard the redundant
	trailing zeros output by date --resolution.
	Reported by Bruno Haible on macOS.

	numfmt: ensure fields don't split on nbsp
	* src/numfmt.c (newline_or_blank): Explicitly ensure
	we don't match NBSP as on platforms like NetBSD 10 or Solaris 11,
	NBSP is considered a blank character.
	This should have been part of commit v9.8-39-g8bc11f80a
	Solaris 11 test failure reported by Bruno Haible.

2025-10-27  Collin Funk  <collin.funk1@gmail.com>

	maint: prefer FTS_ROOTLEVEL when checking the fts_level of an FTSENT
	* src/chcon.c (process_file): Use FTS_ROOTLEVEL instead of 0.
	* src/chmod.c (process_file): Likewise.
	* src/chown-core.c (change_file_owner): Likewise.

	timeout: use the more efficient posix_spawn to invoke the command
	* NEWS: Mention the improvement. Consolidate the posix_spawn
	improvements into one item.
	* bootstrap.conf (gnulib_modules): Add posix_spawnattr_setsigmask.
	* src/timeout.c: Include spawn.h.
	(main): Setup signals using a posix_spawnattr_t object. Use posix_spawn
	instead of fork and execvp.

	maint: prefer ckd_add for overflow checks
	* src/cksum.c (cksum_slice8, crc32b_sum_stream): Use ckd_add to check
	for overflow.
	* src/cksum_avx2.c (cksum_avx2): Likewise.
	* src/cksum_avx512.c (cksum_avx512): Likewise.
	* src/cksum_pclmul.c (cksum_pclmul): Likewise.
	* src/cksum_vmull.c (cksum_vmull): Likewise.

2025-10-27  Pádraig Brady  <P@draigBrady.com>

	build: don't build chcon or runcon unless selinux is available
	The build can be force enabled with --with-selinux and vice versa.

	* build-aux/gen-lists-of-programs.sh: Move chcon and runcon
	to the list of optional programs.
	* configure.ac: Only enable chcon and runcon if selinux.h is available.
	* NEWS: Mention the Build-related change.
	Fixes https://github.com/coreutils/coreutils/issues/121

2025-10-25  Collin Funk  <collin.funk1@gmail.com>

	sort: use the more efficient posix_spawn to invoke --compress-program
	* NEWS: Mention the improvement. Mention that 'sort' will continue
	without compressing temporary files if the program specified by
	--compress-program cannot be executed.
	* doc/coreutils.texi (sort invocation): Document the behavior when the
	program specified by --compress-program cannot be executed.
	* src/sort.c: Include spawn.h.
	(MAX_FORK_TRIES_COMPRESS, MAX_FORK_TRIES_DECOMPRESS): Remove definition.
	(MAX_TRIES_COMPRESS, MAX_TRIES_DECOMPRESS): New definitions based on
	MAX_FORK_TRIES_COMPRESS and MAX_FORK_TRIES_DECOMPRESS.
	(async_safe_die): Remove function.
	(posix_spawn_file_actions_move_fd): New function.
	(pipe_fork): Remove function.
	(pipe_child): New function based on pipe_fork. Return an error number
	instead of a pid. Use posix_spawnp instead of calling fork and expecting
	the caller to exec.
	(maybe_create_temp): Call pipe_child instead of pipe_fork. Print a
	warning to standard error if --compress-program cannot be executed and
	the error is different than the previous call. Remove code for the child
	process.
	(open_temp): Remove code for the child process. Improve error message.
	* tests/sort/sort-compress.sh: Add a test case for when the program
	specified by --compress-program does not exist.

2025-10-23  Collin Funk  <collin.funk1@gmail.com>

	maint: remove unnecessary ignore_value usage
	* src/install.c: Remove ignore-value.h include.
	(strip): Don't use ignore_value on posix_spawnattr_destroy since it
	isn't declared with the warn_unused_result attribute. Pass the checked
	pointer to posix_spawnattr_destroy instead of the variable it points to.

2025-10-23  Bernhard Voelker  <mail@bernhard-voelker.de>

	install: enhance error diagnostic when running strip fails
	* src/install.c (strip): Mention explicitly that the strip program
	failed in the case the user specified a custom strip program name.

2025-10-23  Collin Funk  <collin.funk1@gmail.com>

	split: cleanup after posix_spawn
	* boostrap.conf (gnulib_modules): Add posix_spawn_file_actions_destroy.
	* src/split.c (cleanup): Call posix_spawnattr_destroy and
	posix_spawn_file_actions_destroy after a successful posix_spawn.

	split: prefer posix_spawn to fork and execl
	* NEWS: Mention the change.
	* bootstrap.conf (gnulib_modules): Add posix_spawn,
	posix_spawnattr_setsigdefault, posix_spawn_file_actions_addclose,
	posix_spawn_file_actions_adddup2, and posix_spawn_file_actions_init.
	* src/split.c: Include spawn.h.
	(create): Use posix_spawn instead of fork and execl.

2025-10-23  Pádraig Brady  <P@draigBrady.com>

	tests: date: test --resolution and %-N
	* tests/date/resolution.sh: New test for --resolution and %-N.
	* tests/local.mk: Reference the new test.

	tests: date: test --reference
	* tests/date/reference.sh: Ensure the -r option is tested.
	* tests/local.mk: Add the test.

2025-10-22  Pádraig Brady  <P@draigBrady.com>

	pr: promptly diagnose write errors
	* src/pr.c (print_page): Exit promptly for `yes | pr`.
	(print_clump): Exit promptly for `pr < /dev/zero`.
	* tests/misc/write-errors.sh: Enable test cases.
	* NEWS: Mention the improvement.

	nl: promptly diagnose write errors
	* NEWS: Mention the improvement.
	* src/nl.c (process_file): Exit if error outputting line.
	* tests/misc/write-errors.sh: Enable the test case.

	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.

	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.

2025-10-22  Collin Funk  <collin.funk1@gmail.com>

	install: prefer posix_spawnp to fork and execlp
	* NEWS: Mention the change.
	* bootstrap.conf (gnulib_modules): Add posix_spawnattr_destroy,
	posix_spawnattr_init, posix_spawnattr_setflags, and posix_spawnp.
	* src/install.c (strip): Use posix_spawnp instead of fork and execlp.

2025-10-20  Collin Funk  <collin.funk1@gmail.com>

	maint: remove a redundant write after mcel_scan returns an error
	* gl/lib/mbbuf.h (mbbuf_get_char): Don't set G.len to 1, since mcel_err
	has already done it.

2025-10-20  Pádraig Brady  <P@draigBrady.com>

	tests: numfmt: add non-utf8 multi-byte test
	* tests/numfmt/mb-non-utf8.sh: Test GB18030 delimiter search.
	* tests/local.mk: Reference the new test, and move
	the existing numfmt.pl test from tests/misc to tests/numfmt.

	numfmt: optimize multi-byte --delimiter search
	* src/numfmt.c (is_utf8_charset): A new function to efficiently
	determine if running with a UTF-8 charset.
	(mbsmbchr): A new function to efficiently search for
	a (multi-byte) character in a multi-byte string.
	(next-field): Use mbsmbchr() rather than mbstr() directly.

	numfmt: support multi-byte --delimiter
	* bootstrap.conf: Depend on mbsstr() to robustly search for a
	multi-byte delimiter character (string) within a multi-byte string.
	* src/numfmt.c (main): Accept a valid multi-byte delimiter character.
	(next_field): Adjust delimiter search from single byte
	to multi-byte aware.  Use mbsstr to find the first match.
	* tests/misc/numfmt.pl: Add test case.
	* NEWS: Mention the improvement.

2025-10-18  Pádraig Brady  <P@draigBrady.com>

	numfmt: use multi-byte aware suffix matching
	* src/numfmt.c (process_suffixed_number): Use gnulib's
	mbs_endswith() helper, which is more robust in non UTF-8 locales.
	Also always output a devmsg if a suffix is specified.

	numfmt: fix issues with multi-byte blanks
	* src/numfmt.c (process_line): Restore byte overwritten with NUL,
	as it may be part of a multi-byte blank.
	(process_suffixed_number): Skip multi-byte blanks,
	and correctly determine width with mbswidth().
	(parse_format_string): Use c_isblank() to explicitly
	indicate that's all the format spec supports.
	* tests/misc/numfmt.pl: Add test cases.
	* NEWS: Mention the bug fix.

2025-10-17  Pádraig Brady  <P@draigBrady.com>

	numfmt: add --unit-separator
	Output, accept, or disallow a string between the number and unit
	as recommended in <https://physics.nist.gov/cuu/Units/checklist.html>
	I.e. support outputting numbers of the form: "1234 M"

	* src/numfmt.c (simple_strtod_human): Skip unit separator if present,
	or disallow a unit separator if empty.
	(double_to_human): Output unit separator if specified.
	(main): Accept --unit-separator.
	* tests/misc/numfmt.pl: Add test cases.
	* doc/coreutils.texi: Describe the new option,
	giving examples of interaction with --delimiter.
	* NEWS: Mention the new feature.
	* THANKS.in: Add Johannes Schauer Marin Rodrigues,
	who provided a preliminary patch.

2025-10-17  Pádraig Brady  <P@draigBrady.com>

	numfmt: support reading numbers with grouping characters
	This does not validate grouping character placement,
	and currently just ignores grouping characters.

	* src/numfmt.c (simple_strtod_int): Skip grouping chars
	that are part of a number.
	* tests/misc/numfmt.pl: Add test cases.
	* NEWS: Mention the improvement.

2025-10-17  Pádraig Brady  <P@draigBrady.com>

	numfmt: support reading numbers with NBSP before unit
	* src/numfmt.c (simple_strtod_human): Accept (multi-byte)
	non-breaking space character between number and unit.
	Note we restrict this to a single character between number
	and unit, to allow less ambiguous parsing if multiple blanks
	are used to delimit fields.
	* tests/misc/numfmt.pl: Add test cases.
	* doc/coreutils.texi (numfmt invocation): Fix stale description
	--delimiter skipping whitespace.
	* NEWS: Mention the improvement.

2025-10-16  Nicolas Boichat  <nicolas@boichat.ch>

	tests: du/bigtime: try harder to find a suitable filesystem
	* tests/du/bigtime.sh: At least on Linux, the ext4 filesystem
	doesn't support such large timestamp, while tmpfs does.  Try a bit
	harder to look for a filesystem with large timestamp support.

2025-10-14  Collin Funk  <collin.funk1@gmail.com>
	    Pádraig Brady  <P@draigBrady.com>

	tests: date: check that the hour format of the current locale is used
	* tests/date/date-locale-hour.sh: New file.
	* tests/local.mk (all_tests): Add the new test.

2025-10-13  Pádraig Brady  <P@draigBrady.com>

	tests: fix false failure in recent memory limit test
	* tests/basenc/bounded-memory.sh: Ensure we skip the test
	upon failure to determine the memory lower bound.
	Reported by Bruno Haible.

2025-10-11  Pádraig Brady  <P@draigBrady.com>

	numfmt: fix buffer over-read (CWE-126)
	* src/numfmt.c (simple_strtod_human): Check for NULL after pointer
	adjustment to avoid Out-of-range pointer offset (CWE-823).
	* NEWS: Mention the fix.

2025-10-11  Pádraig Brady  <P@draigBrady.com>

	tests: basenc: use less redundant naming
	Rename to less redundant names, now that we use
	a separate test directory per util.

	* tests/basenc/basenc-bounded-memory.sh -> .../bounded-memory.sh
	* tests/basenc/basenc-large.sh -> .../large-input.sh
	* tests/local.mk: Reference new names.

2025-10-11  Pádraig Brady  <P@draigBrady.com>

	tests: fix memory limit determination in new test
	* tests/basenc/basenc-bounded-memory.sh: The passed command
	needs to succeed for memory limit determination to work.

2025-10-11  Collin Funk  <collin.funk1@gmail.com>

	tests: basenc: add a test for bounded memory operation
	* tests/basenc/basenc-bounded-memory.sh: New file.
	* tests/local.mk (all_tests): Add the test.

2025-10-10  Sylvestre Ledru  <sylvestre@debian.org>

	tests: ln -f: ensure existing link replaced
	Identified here:
	<https://github.com/uutils/coreutils/issues/8830>

	* tests/ln/misc.sh: Add the check.

2025-10-07  Pádraig Brady  <P@draigBrady.com>

	tests: cksum: add a test case for robust file name parsing
	* tests/cksum/cksum-c.sh: Add a test case where the file name
	contains tagged format delimiter characters.

	maint: cksum: document a base64/hex parsing ambiguity with untagged
	* src/digest.c (split_3): Mention the ambiguity in misinterpreting
	base64 characters as hex is not a practical consideration.
	Also add an example of both tagged formats which makes it
	easier to interpret the parsing logic.

	cksum: fix --check with untagged base64 format with tag matches
	* src/digest.c (split_3): Fallback to untagged matching in the
	case where -a is specified and we have matched a TAG in
	the possibly base64 data.  This might happen in 1 in every 64K files.
	Note we remove the modification of string S (and redundant streq) in
	the tag matching, as that was not needed since v8.32-223-g217cd278e.
	* tests/cksum/cksum-c.sh: Add a test case.
	* NEWS: Mention the bug fix.

	cksum: fix length validation with SHA2- tagged format
	* src/digest.c (sha2_sum_stream): Change from unreachable()
	to affirm() so that we have defined behavior unless
	we configure with --disable-assert.
	(sha3_sum_stream): Likewise.
	(split_3): Validate SHA2-lengths before passing on.
	* tests/cksum/cksum-c.sh: Add a test case.
	* NEWS: Mention the bug fix.

	cksum: fix --check with --algorithm=sha2
	* src/digest.c (split_3): Look up the provided tag with -a sha2
	because there is not a 1:1 mapping between them.
	* tests/cksum/cksum-c.sh: Add a test case.
	* NEWS: Mention the bug fix.

2025-10-06  Paul Eggert  <eggert@cs.ucla.edu>

	rm: remove redundant mark_ancestor_dirs call
	* src/remove.c (rm_fts): Remove unnecessary call.  Since this code
	is executed only when not recursive, there are no ancestors to mark.

	rm: make ‘rm -d DIR’ more like ‘rmdir DIR’
	* src/remove.c (rm_fts): When not recursive,
	arrange for ‘rm -d DIR’ to behave more like ‘rmdir DIR’.
	This works better for Ceph snapshot directories.
	Problem reported by Yannick Le Pennec (bug#78245).

2025-10-05  Collin Funk  <collin.funk1@gmail.com>

	cksum: allow -a {blake2b,sha2,sha3} --check to work on base64
	* NEWS: Mention the bug.
	* src/digest.c (split_3): Check that the base64 digest matches the
	length supported by the algorithm.
	(digest_check): Check that the read digest matches the base64 length of
	the algorithm's digest. The previous condition would not work for
	'cksum -a blake2b -l 8 ...'.
	* tests/cksum/cksum-base64-untagged.sh: New file.
	* tests/local.mk (all_tests): Add the new test.

2025-10-04  Paul Eggert  <eggert@cs.ucla.edu>

	maint: omit trailing white space in config.h
	* configure.ac (FORTIFY_SOURCE): Don’t indent a line
	where the indentation can cause trailing white space in config.h.
	Problem reported by Grisha Levit (Bug#79567).

2025-10-03  Collin Funk  <collin.funk1@gmail.com>

	maint: remove IRIX support
	* src/ptx.c (main) [HAVE_SETCHRCLASS]: Remove call to setchrclass.
	* src/stty.c (VREPRINT) [!VREPRINT && VRPRNT]: Remove definition.

2025-10-02  Pádraig Brady  <P@draigBrady.com>

	tests: factor: add suggested large prime tests
	* tests/factor/create-test.sh: Add 2 new large primes from:
	https://github.com/coreutils/coreutils/issues/65
	* tests/local.mk: Reference the 2 new generated tests.

2025-10-02  Pádraig Brady  <P@draigBrady.com>

	unexpand: fix heap buffer overflow with --tabs=[+/]NUM
	This avoids CWE-122: Heap-based Buffer Overflow
	where we could write blank characters beyond
	the allocated heap buffer.

	* src/expand-common.c (set_max_column_width): Refactor function from ...
	(add_tab_stop): ... here.
	(set_extend_size): Call new function.
	(set_increment_size): Likewise.
	* NEWS: Mention the bug fix.
	Fixes https://bugs.gnu.org/79555

2025-10-02  Pádraig Brady  <P@draigBrady.com>

	doc: man: consistently format -X[OPTIONAL] form
	This is significant for the date, od, and pr commands
	which have options of the form -X[OPTIONAL], which change like:

	  diff -r man.orig/date.1 man/date.1
	  < \fB\-I[FMT]\fR, \fB\-\-iso\-8601\fR[=\fI\,FMT\/\fR]
	  > \fB\-I\fR[\fI\,FMT\/\fR], \fB\-\-iso\-8601\fR[=\fI\,FMT\/\fR]

	  diff -r man.orig/od.1 man/od.1
	  < \fB\-w[BYTES]\fR, \fB\-\-width\fR[=\fI\,BYTES\/\fR]
	  > \fB\-w\fR[\fI\,BYTES\/\fR], \fB\-\-width\fR[=\fI\,BYTES\/\fR]

	* man/help2man (convert_options): Support options of the form
	-X[PARAM], so that we now consistently format them (in italics).

2025-10-02  Pádraig Brady  <P@draigBrady.com>

	doc: man: consistently italicize --option parameters
	This changes a few pages, but the changes in tail.1
	concisely illustrate the resulting man page changes:

	  $ diff -r man.orig/tail.1 man/tail.1
	  < \fB\-c\fR, \fB\-\-bytes\fR=\fI\,[\/\fR+]NUM
	  > \fB\-c\fR, \fB\-\-bytes\fR=\fI\,[+]NUM\/\fR

	  < \fB\-f\fR, \fB\-\-follow[=\fR{name|descriptor}]
	  > \fB\-f\fR, \fB\-\-follow\fR[=\fI\,{name|descriptor}\/\fR]

	  < \fB\-n\fR, \fB\-\-lines\fR=\fI\,[\/\fR+]NUM
	  > \fB\-n\fR, \fB\-\-lines\fR=\fI\,[+]NUM\/\fR

	* man/help2man: Relax the option match so more --option
	variations are supported, and passed through to convert_option().
	Specifically more variations after '=' are now supported.
	Also split and document the regular expression.
	Reported at https://github.com/coreutils/coreutils/issues/84

2025-10-02  Collin Funk  <collin.funk1@gmail.com>

	maint: prefer unreachable () to NOTREACHED comment
	* src/tsort.c (search_item): Use unreachable () instead of NOTREACHED.

2025-10-01  Collin Funk  <collin.funk1@gmail.com>

	fold: move multi-byte character reading to a module
	* gl/modules/mbbuf: New file.
	* gl/lib/mbbuf.c: Likewise.
	* gl/lib/mbbuf.h: Likewise.
	* gl/local.mk (EXTRA_DIST): Add the new files.
	* bootstrap.conf (gnulib_modules): Add mbbuf.
	* src/fold.c: Include mbbuf.h.
	(fold_file): Use the mbbuf functions instead of calling fread and
	handling the input buffer ourselves.
	* cfg.mk (exclude_file_name_regexp--sc_preprocessor_indentation)
	(exclude_file_name_regexp--sc_GPL_version): Match gl/lib/mbbuf.c and
	gl/lib/mbbuf.h.

2025-09-30  Mathieu Bordere  <mathieu@letmetweakit.com>

	wc: add AVX512 function for line counting
	* configure.ac: Add detection of AVX512 intrinsics for wc.
	* src/local.mk: Build AVX512 wc libraries.
	* src/wc.c: Add runtime detection of AVX512 intrinsics and call
	appropriate function when detected.
	* src/wc.h (wc_lines_avx512): Declare function.
	* tests/wc/wc-cpu.sh: Add a test that disables AVX512 intrinsics.
	* src/wc_avx512.c: New file containing the wc -l implementation using
	AVX512. The logic and code is reused from the AVX2 implementation with
	slight adaptations. Replaced __builtin_popcount by __builtin_popcountll
	and the combination of _mm256_cmpeq_epi8 and _mm256_movemask_epi8 by a
	single call to _mm512_cmpeq_epi8_mask.
	* NEWS: Mention the improvement.

2025-09-28  Pádraig Brady  <P@draigBrady.com>

	maint: update valgrind instructions
	* README-valgrind: Adjust to current repo structure,
	and give clearer step by step instructions.

2025-09-27  Collin Funk  <collin.funk1@gmail.com>

	maint: convert some overflow checks to ckd_add and ckd_mul
	* src/csplit.c (parse_repeat_count): Prefer ckd_add when checking for
	overflows.
	* src/install.c (get_ids): Likewise.
	* src/shred.c (dopass): Likewise.
	* src/tr.c (get_spec_stats): Likewise.
	* src/sort.c (specify_sort_size): Prefer ckd_mul when checking for
	overflows.

2025-09-26  Pádraig Brady  <P@draigBrady.com>

	tests: test: ensure file operations are covered
	A coverage report indicated these weren't tested
	(as generally the test shell builtin is used).

	* tests/test/test-file.sh: Add a new test.
	* tests/local.mk: Reference the new test.

2025-09-26  Bernhard Voelker  <mail@bernhard-voelker.de>

	join: remove unused #include "argmatch.h"
	Prompted by the syntax-check failure:
	  maint.mk: the above files include argmatch.h but don't use it
	  make: *** [maint.mk:741: sc_prohibit_argmatch_without_use] Error 1

	* src/join.c: Remove include, as the previous commit changed from using
	ARRAY_CARDINALITY to countof - for which system.h includes the header.

2025-09-25  Collin Funk  <collin.funk1@gmail.com>

	maint: prefer countof over ARRAY_CARDINALITY
	* bootstrap.conf (gnulib_modules): Add stdcountof-h.
	* src/system.h: Include stdcountof.h.
	(ARRAY_CARDINALITY): Remove definition.
	* .gitignore (/lib/stdcountof.h): Ignore Gnulib generated file.
	* src/csplit.c: Use countof instead of ARRAY_CARDINALITY.
	* src/df.c: Likewise.
	* src/digest.c: Likewise.
	* src/dircolors.c: Likewise.
	* src/factor.c: Likewise.
	* src/join.c: Likewise.
	* src/ls.c: Likewise.
	* src/od.c: Likewise.
	* src/sort.c: Likewise.
	* src/stdbuf.c: Likewise.
	* src/tr.c: Likewise.

2025-09-24  Hannes Braun  <hannes@hannesbraun.net>

	tail: fix tailing larger number of lines in regular files
	* src/tail.c (file_lines): Seek to the previous block instead of the
	beginning (or a little before) of the block that was just scanned.
	Otherwise, the same block is read and scanned (at least partially)
	again. This bug was introduced by commit v9.7-219-g976f8abc1.
	* tests/tail/basic-seek.sh: Add a new test.
	* tests/local.mk: Reference the new test.
	* NEWS: mention the bug fix.

2025-09-24  Pádraig Brady  <P@draigBrady.com>

	tests: wc: fix hardware acceleration disabling test
	* tests/wc/wc-cpu.sh: The message is only printed with wc -l.
	Reported by Mathieu Borderé.

	build: copy: add dependency on $(LIB_SMACK)
	* src/local.mk: Due to gnulib adjustments, this explicit
	dependency is required with the mold linker at least.
	Reported at https://github.com/coreutils/coreutils/issues/113

2025-09-23  Pádraig Brady  <P@draigBrady.com>

	basenc: --base58: fix buffer overflow with input > 15MB
	base58_length() operated naively on an int
	which resulted in an overflow to a negative number
	for any input > 2^31-1/138, i.e. 15,561,475 bytes.

	* src/basenc.c (base_length): Change input and output
	parameter types from int to idx_t since this needs to
	cater for the full input size in the base58 case.
	(base58_length): Likewise.  Also reorder the calculation
	to be less exact, but doing the division first
	to minimize the chance of overflow (which now on 64 bit
	would only happen for inputs > around 6 Exa bytes).
	* tests/basenc/basenc-large.sh: Add a new test,
	that triggers with valgrind or ASAN.
	* tests/local.mk: Reference the new test.
	* NEWS: Mention the bug fix.

2025-09-23  Pádraig Brady  <P@draigBrady.com>

	doc: document gl_cv_crc_pclmul to control hardware acceleration
	doc/coreutils.texi (Harware acceleration configuration):
	Sort the list and add "gl_cv_crc_pclmul".

	build: fix build failure with mismatched pclmul
	* src/cksum.c (pclmul_supported): In the case where
	gnulib has pclmul enabled but coreutils does not,
	ensure we don't reference the coreutils pclmul function.
	Addresses https://bugs.gnu.org/79491

2025-09-23  Paul Eggert  <eggert@cs.ucla.edu>

	build: update gnulib submodule to latest

2025-09-22  Pádraig Brady  <P@draigBrady.com>

	maint: post-release administrivia
	* NEWS: Add header line for next release.
	* .prev-version: Record previous version.
	* cfg.mk (old_NEWS_hash): Auto-update.

	version 9.8
	* NEWS: Record release date.

	build: update gnulib to latest
	* gnulib: Update to latest to pull Android build fixes,
	and fchownat fixes.

	tests: ls: avoid alignment check with non printable characters
	* tests/ls/block-size.sh: Skip the case where there are
	non-printable characters in ls' output, which is the case
	with NBSP thousands separators on FreeBSD 11 and 12.
	We may drop the MBSW_REJECT_UNPRINTABLE in future from
	ls and numfmt, but for now avoid these characters in the test.
	Reported by Bruno Haible.

	tests: du: avoid false failure in racy test
	* tests/du/move-dir-while-traversing.sh: Expand the work to avoid
	a false failure where du completes before the directory is moved.
	Also expand the timeout to our more standard 10s to avoid the
	"directory mover" being killed before du processes the directory.
	This doesn't perceptibly impact the run time of the test.
	Reported by Bruno Haible on a CentOS 7 system.

	build: revert gnulib update
	There is a pending issue with fchownat:
	https://lists.gnu.org/r/bug-gnulib/2025-09/msg00282.html

2025-09-21  Collin Funk  <collin.funk1@gmail.com>

	build: update gnulib submodule to latest

	build: fix missing declarations on Android
	* configure.ac: Check for statx using gl_CHECK_FUNCS_ANDROID since it is
	hidden for Android API level <= 30.
	* m4/jm-macros.m4 (coreutils_MACROS): Check for syncfs using
	gl_CHECK_FUNCS_ANDROID since it is hidden for Android API level <= 28.

2025-09-21  Paul Eggert  <eggert@cs.ucla.edu>

	maint: comment spelling fixes

	tests: fix OMP_NUM_THREADS misspelling
	* tests/nproc/nproc-quota.sh: Fix misspelling.

	maint: update bootstrap from Gnulib

2025-09-21  Pádraig Brady  <P@draigBrady.com>

	tests: avoid false failure on older Linux kernels
	* tests/fold/fold-zero-width.sh: Check the shell was able to create
	the redirection file, as intermittently on CentOS 5,6,7 this wasn't
	the case, with the shell giving an xmalloc failure due to the ulimit.
	Reported by William Bader and Bruno Haible.

	tests: tail: avoid false failure with overlayfs
	* tests/tail/inotify-dir-recreate.sh: Add an extra check
	that inotify is in use, as it's required for this test.
	Inotify is avoided with overlayfs for which the
	df --local check is not sufficient exclusion for.

2025-09-20  Pádraig Brady  <P@draigBrady.com>

	tests: fold: avoid false failures on Solaris 10
	* tests/fold/fold-characters.sh: Ensure we have independent verification
	of the width of characters before testing based on those widths.
	* tests/fold/fold-zero-width.sh: Likewise.
	* tests/fold/fold.pl: Only compare the exit status,
	as the error message can be translated.

	tests: dd: avoid false failure on Solaris 10
	* tests/dd/no-allocate.sh: Give some extra space to the
	determined vm limit.

	tests: avoid false failure on CentOS 5,6,7
	* tests/fold/fold-zero-width.sh: Increase vm limit to avoid
	failures on CentOS 5,6,7.  Match the limit used in write-errors.sh
	as per commit v9.5-255-g0bd149403

2025-09-20  Collin Funk  <collin.funk1@gmail.com>

	doc: don't capitalize the first letter of cgroup
	This is the correct way to write it as described in the documentation:
	<https://docs.kernel.org/admin-guide/cgroup-v2.html#terminology>.

	* doc/coreutils.texi (nproc invocation): Use cgroup instead of Cgroup.

2025-09-20  Collin Funk  <collin.funk1@gmail.com>

	tests: env: skip a few tests if LD_LIBRARY_PATH is set
	* tests/env/env-null.sh: Skip test if LD_LIBRARY_PATH or platform's
	equivalent is set, since 'env -i' will unset it which may prevent
	programs from running.
	* tests/env/env-S.pl: Likewise.
	Issue and suggested fix reported by Bruno Haible.

2025-09-19  Grisha Levit  <grishalevit@gmail.com>

	touch: fix diagnostic on macOS 26
	* src/touch.c (touch): Do not use open_errno == EEXIST for diagnostic
	if file was a directory as macOS 26 sets it for open("/", O_CREAT, ...).

2025-09-19  Paul Eggert  <eggert@cs.ucla.edu>

	copy: pacify older clang
	* src/copy-file-data.c (copy_file_data):
	Redo conditionals for clarity.
	This pacifies the clang in FreeBSD 11 and OpenBSD 7.6.
	Problem reported by Bruno Haible in:
	https://lists.gnu.org/r/coreutils/2025-09/msg00104.html

2025-09-19  Collin Funk  <collin.funk1@gmail.com>

	dd: don't mistakenly use O_EXCL on GNU/Hurd
	* src/dd.c (v): Add the O_EXCL flag to the set of bits that we do not
	want to use for our definitions.
	* cfg.mk (sc_dd_O_FLAGS): Adjust to pass syntax-check.
	* NEWS: Mention the fix.
	Reported by Bruno Haible.
[--snip--]
