]> git.ipfire.org Git - thirdparty/coreutils.git/commit
tests: cp: --remove-destination must honor the same-file check
authorSylvestre Ledru <sylvestre@debian.org>
Thu, 25 Jun 2026 19:14:00 +0000 (21:14 +0200)
committerPádraig Brady <P@draigBrady.com>
Mon, 29 Jun 2026 19:42:59 +0000 (20:42 +0100)
commit0eb2fff6130a37770b6b66cb91d680a2f600d1da
treed4ae70de52759b31c2fcdea73343f93b2ec1a044
parent52ff9b97fbf6910dc6f04ad1fdb2d1851feb417b
tests: cp: --remove-destination must honor the same-file check

* tests/cp/same-file.sh: A different spelling of the same path
('foo' vs './foo') must still be detected as the same file, so
--remove-destination refuses instead of unlinking the source.

Link: https://github.com/coreutils/coreutils/pull/302
tests/cp/same-file.sh