-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Closed
Labels
Description
Although uncommon and probably unwise, linux filenames can end in slash.
uutils-coreutils appears to wrongfull intrepret those as directories and fails copying.
repro:
# cp -V
cp (uutils coreutils) 0.2.2
# mkdir a
# touch a/foo\\
# cp -r a b
cp: 'b/foo\' is not a directory
# ls -la b
total 1
drwxr-xr-x 2 root root 2 Sep 24 23:07 .
drwx------ 6 root root 9 Sep 24 23:07 ..
expected:
# gnucp -r a gnu_b
# ls -la gnu_b/
total 1
drwxr-xr-x 2 root root 3 Sep 24 23:07 .
drwx------ 6 root root 9 Sep 24 23:07 ..
-rw-r--r-- 1 root root 0 Sep 24 23:07 'foo\'