Skip to content

Commit 75ff8ac

Browse files
committed
tests/csplit: use printf instead of echo -n for maximum portability with all UNIX systems
1 parent 5f8d357 commit 75ff8ac

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tests/by-util/test_csplit.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1433,7 +1433,7 @@ fn create_named_pipe_with_writer(path: &str, data: &str) -> std::process::Child
14331433
nix::unistd::mkfifo(path, nix::sys::stat::Mode::S_IRWXU).unwrap();
14341434
std::process::Command::new("sh")
14351435
.arg("-c")
1436-
.arg(format!("echo -n '{}' > {path}", data))
1436+
.arg(format!("printf '{}' > {path}", data))
14371437
.spawn()
14381438
.unwrap()
14391439
}

0 commit comments

Comments
 (0)