feat: make cat even more busybox-like

This commit is contained in:
user0-07161 2025-03-21 19:45:14 +01:00
parent aef41f2c18
commit 7ae11ea80b

View file

@ -12,6 +12,10 @@ impl Command for Cat {
let arguments: Vec<String> = get_args(String::from("cat"), args);
let mut vecbuf = Vec::new();
if arguments.len() == 0 {
let _ = io::stdin().read_to_end(&mut vecbuf);
}
for file in arguments.iter() {
let mut tmpbuf = Vec::new();
let mut read = BufReader::new(File::open(file).unwrap());