Open tavianator opened 2 years ago
What is the expected behavior? Many path constraints seem to be limited to the underlying filesystem. It also wouldn't surprise me on Linux if bash and zsh also have shell dependent limits.
https://serverfault.com/questions/9546/filename-length-limits-on-linux https://eklitzke.org/path-max-is-tricky
The shell specific dependencies do bother me - I have seen other errors break TTY settings on bash that run fine under zsh. I would like an AWK style test suite for this project https://www.cs.princeton.edu/courses/archive/spring01/cs333/awktest.html
Perhaps a tests/shell folder?
I would expect it to just copy the file. There's no need to compute the full absolute path.
PATH_MAX
applies to many things but there's no need for it to limit the current working directory.
Is this error already documented?
---- test_cp::test_closes_file_descriptors stdout ----
current_directory_resolved:
run: /path/coreutils/target/debug/coreutils cp -r --reflink=auto dir_with_10_files/ dir_with_10_files_new/
thread 'test_cp::test_closes_file_descriptors' panicked at 'Command was expected to succeed.
stdout =
stderr = cp: '/tmp/.tmpVx5ebK/dir_with_10_files/7' -> 'dir_with_10_files_new/7': Too many open files (os error 24)
', tests/common/util.rs:166:9
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Hasn't been fixed yet
https://github.com/uutils/coreutils/issues/2688#issuecomment-955769210
the test_cp::test_closes_file_descriptors ... ok
passes,
and the initial report
$ name="0123456789ABCDEF" $ name="${name}${name}${name}${name}" $ name="${name}${name}${name}${name}" $ name="${name:0:255}" $ mkdir deep && cd deep && for i in {1..17}; do mkdir $name && cd $name; done $ touch foo $ cp foo bar
also works
# pwd | wc -m
4375
# RUST_BACKTRACE=1 /mnt/p2/coreutils/target/release/coreutils cp foo baz2
Might this be considered for closing, then?
I saw commit https://github.com/uutils/coreutils/pull/2624/commits/ef9c5d4fcf13fdc0c7bc8f3a8d14f84c3986ee51 and figured I should test this situation: