[Bug 124084] find(1): find -execdir does not prepend ./ to filenames, causing problems for certain files.
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Mon Jan 28 21:42:41 UTC 2019
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=124084
Oleksandr Tymoshenko <gonzo at FreeBSD.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|Open |Closed
CC| |gonzo at FreeBSD.org
Resolution|--- |Works As Intended
--- Comment #4 from Oleksandr Tymoshenko <gonzo at FreeBSD.org> ---
This is breaking behavior, I think a lot of existing scripts using find(1) rely
on filenames to be prefix-less. The easy way to work around this is to use '--'
marker to separate arguments from files:
% cat x.sh
mkdir -p /tmp/test
cd /tmp/test
>"-foo"
find . -type f -execdir ls -la -- {} \;
% sh x.sh
-rw-r--r-- 1 gonzo wheel 0 Jan 28 13:42 -foo
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the freebsd-bugs
mailing list