Follow-up Comment #2, bug #46305 (project findutils):
I think this is an actual bug, despite the general danger of running -delete
together with -L. In this setup:
$ mkdir foo
$ mkdir bar
$ ln -s ../foo bar/baz
$ find -L bar -delete
find: cannot delete ‘bar/baz’: Not a directory
find: cannot delete ‘bar’: Directory not empty
(No -type d necessary.) strace shows that find tried to
unlinkat(AT_FDCWD, "bar/baz", AT_REMOVEDIR) = -1 ENOTDIR (Not a directory)
but "bar/baz" is not a directory so AT_REMOVEDIR is wrong.
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?46305>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/