1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-09-16 19:56:17 +00:00

Merge pull request #3148 from jfinkels/dd-of-dev-null

dd: don't error when outfile is /dev/null
This commit is contained in:
Sylvestre Ledru 2022-02-21 17:10:42 +01:00 committed by GitHub
commit 419abec4e5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 16 additions and 2 deletions

View file

@ -1095,3 +1095,10 @@ fn test_truncated_record() {
.stdout_is("ac")
.stderr_is("0+1 records in\n0+1 records out\n2 truncated records\n");
}
/// Test that the output file can be `/dev/null`.
#[cfg(unix)]
#[test]
fn test_outfile_dev_null() {
new_ucmd!().arg("of=/dev/null").succeeds().no_stdout();
}