Jim Meyering <j...@meyering.net> writes: > I'm confident that POSIX does not require > cp -r dir dir to create dir/dir ;-)
That's certainly true: an implementation is clearly allowed to (but not required to) report an error and exit without doing anything when it sees this example. However, that's not what GNU cp does, which raises the issue. As near as I can figure out, this is a hole in POSIX. It nowhere specifies what "cp" should do when inputs and outputs overlap, which they can in even-more-interesting ways than "cp -R dir dir". Perhaps this should be raised with the POSIX folks, but in the meantime I don't see that GNU cp needs to change as far as conformance goes. _______________________________________________ Bug-coreutils mailing list Bug-coreutils@gnu.org http://lists.gnu.org/mailman/listinfo/bug-coreutils