# cp /dev/null foo
cp: /dev/null: Invalid argument
This message is output due to changes in r365549.
^Triage: over to committer of r365549.
Fix is in code review
A commit references this bug:
Date: Fri Sep 11 20:49:37 UTC 2020
New revision: 365643
cp: fall back to read/write if copy_file_range fails
Even though copy_file_range has a file-system agnostic version, it still
fails on devfs (perhaps because the file descriptor is non-seekable?) In
that case, fallback to old-fashioned read/write. Fixes
"cp /dev/null /tmp/null"
Reported by: Michael Butler
Reviewed by: mjg
Differential Revision: https://reviews.freebsd.org/D26395
(In reply to commit-hook from comment #3)
It's fine. Thanks.
Fixed by 365643. The bug was never introduced to any stable branch.