Revert to the default behavior before the introduction of statx().
* src/stat.c (do_stat): Set AT_NO_AUTOMOUNT without --cached=never.
* doc/coreutils.texi (stat invocation): Mention the automount
behavior with --cached=never.
* NEWS: Mention the change in behavior.
Fixes https://bugs.gnu.org/54287
ls no longer tries to automount files, reverting to the behavior
before the statx() call was introduced in coreutils-8.32.
+ stat no longer tries to automount files by default, reverting to the
+ behavior before the statx() call was introduced in coreutils-8.32.
+ Only `stat --cached=never` will continue to automount files.
+
timeout --foreground --kill-after=... will now exit with status 137
if the kill signal was sent, which is consistent with the behavior
when the --foreground option is not specified. This allows users to
@item never
Always sychronize with the latest file system attributes.
+This also mounts automounted files.
@item default
Leave the caching behavior to the underlying file system.
else if (force_sync)
flags |= AT_STATX_FORCE_SYNC;
+ if (! force_sync)
+ flags |= AT_NO_AUTOMOUNT;
+
fd = statx (fd, pathname, flags, format_to_mask (format), &stx);
if (fd < 0)
{