Fix -o option

This commit is contained in:
Minseong Jang
2022-02-24 19:00:28 +09:00
parent 9da544d942
commit b5f8858825

View File

@@ -86,7 +86,7 @@ fn main() {
let mut output: Box<dyn ::std::io::Write> = if output == "-" {
Box::new(::std::io::stdout())
} else {
Box::new(ok_or_exit!(::std::fs::File::open(output), 1))
Box::new(ok_or_exit!(::std::fs::File::create(output), 1))
};
let ext = input.extension();