Commit 75939047 authored by topjohnwu's avatar topjohnwu

Fix bugs in compression

parent 2d7f130d
...@@ -109,7 +109,7 @@ void compress(const char *method, const char *infile, const char *outfile) { ...@@ -109,7 +109,7 @@ void compress(const char *method, const char *infile, const char *outfile) {
rm_in = true; rm_in = true;
} }
} else { } else {
out_fd = strcmp(infile, "-") == 0 ? STDOUT_FILENO : creat(infile, 0644); out_fd = strcmp(outfile, "-") == 0 ? STDOUT_FILENO : creat(outfile, 0644);
} }
cmp->set_out(make_unique<FDOutStream>(out_fd)); cmp->set_out(make_unique<FDOutStream>(out_fd));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment