erofs-utils: fuse: fix partial decompression for libdeflate
authorGao Xiang <hsiangkao@linux.alibaba.com>
Fri, 9 Aug 2024 10:56:36 +0000 (18:56 +0800)
committerGao Xiang <hsiangkao@linux.alibaba.com>
Fri, 9 Aug 2024 16:19:14 +0000 (00:19 +0800)
commit8895abbc282edd5ea795f971b43b0a601a0b443d
treeb93c08958808b08b33fb909ae20403fcf9c0dde4
parentb9b6493e6010445f36183cfa630353f82bbf6b44
erofs-utils: fuse: fix partial decompression for libdeflate

Actually, libdeflate doesn't support partial decompression; therefore,
fix it by reallocating larger decompression buffers.

Although a better approach would be to obtain the exact decompressed
length instead for libdeflate decompressor, which requires more changes,
a quick fix is needed.

Fixes: 29b9e7140162 ("erofs-utils: fuse,fsck: add DEFLATE algorithm support")
Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>
Link: https://lore.kernel.org/r/20240809105636.3641536-1-hsiangkao@linux.alibaba.com
lib/decompress.c