[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug #60207] -prune returns false for files for which fstatat() fails wi
From: |
Stephane Chazelas |
Subject: |
[bug #60207] -prune returns false for files for which fstatat() fails with EACCESS |
Date: |
Wed, 10 Mar 2021 07:27:27 -0500 (EST) |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:86.0) Gecko/20100101 Firefox/86.0 |
Follow-up Comment #1, bug #60207 (project findutils):
For the record, comparison with other find implementations on that second
(symlink-based) example on the same system:
$ gnu-find -L . -name 'a*' -prune -o -print
.
./b1
find: ‘./a1’: Permission denied
./a1
./b2
find: ‘./a5’: Not a directory
find: ‘./a4’: Too many levels of symbolic links
$ busybox find -L . -name 'a*' -prune -o -print
.
./b1
find: ./a1: Permission denied
./b2
find: ./a5: Not a directory
find: ./a4: Too many levels of symbolic links
$ sfind -L . -name 'a*' -prune -o -print
.
./b1
./b2
$ heirloom-find -L . -name 'a*' -prune -o -print
.
./b1
heirloom-find: cannot follow symbolic link ./a3: No such file or directory
heirloom-find: cannot follow symbolic link ./a1: Permission denied
./b2
heirloom-find: cannot follow symbolic link ./a5: Not a directory
heirloom-find: cannot follow symbolic link ./a4: Too many levels of symbolic
links
(heirloom-find being the one from the "heirloom toolchest" based on
OpenSolaris, and sfind being from schily-tools).
See also these differences wrt to which files are reported without -prune:
$ find -L . -name 'a*'
./a3
find: ‘./a1’: Permission denied
./a1
find: ‘./a5’: Not a directory
./a5
find: ‘./a4’: Too many levels of symbolic links
./a2
$ busybox find -L . -name 'a*'
./a3
find: ./a1: Permission denied
find: ./a5: Not a directory
find: ./a4: Too many levels of symbolic links
./a2
$ sfind -L . -name 'a*'
./a3
./a1
./a5
./a4
./a2
$ heirloom-find -L . -name 'a*'
heirloom-find: cannot follow symbolic link ./a3: No such file or directory
heirloom-find: cannot follow symbolic link ./a1: Permission denied
heirloom-find: cannot follow symbolic link ./a5: Not a directory
heirloom-find: cannot follow symbolic link ./a4: Too many levels of symbolic
links
./a2
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?60207>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/