Commit 0f92d1de authored by topjohnwu's avatar topjohnwu

Fix bzip2 decompression

parent e59c5c87
...@@ -254,6 +254,7 @@ bool BZStream::update(const void *in, size_t size) { ...@@ -254,6 +254,7 @@ bool BZStream::update(const void *in, size_t size) {
} }
uint64_t BZStream::finalize() { uint64_t BZStream::finalize() {
if (mode)
update(nullptr, 0, BZ_FINISH); update(nullptr, 0, BZ_FINISH);
uint64_t total = ((uint64_t) strm.total_out_hi32 << 32) + strm.total_out_lo32; uint64_t total = ((uint64_t) strm.total_out_hi32 << 32) + strm.total_out_lo32;
switch(mode) { switch(mode) {
......
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