Skip to content

Commit a0961f3

Browse files
committed
erofs: don't trigger WARN() when decompression fails
syzbot reported a WARNING [1] due to corrupted compressed data. As Dmitry said, "If this is not a kernel bug, then the code should not use WARN. WARN if for kernel bugs and is recognized as such by all testing systems and humans." [1] https://lore.kernel.org/r/[email protected] Link: https://lore.kernel.org/r/[email protected] Cc: Dmitry Vyukov <[email protected]> Reviewed-by: Chao Yu <[email protected]> Reported-by: [email protected] Signed-off-by: Gao Xiang <[email protected]>
1 parent eaa9172 commit a0961f3

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

fs/erofs/decompressor.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,6 @@ static int z_erofs_lz4_decompress_mem(struct z_erofs_decompress_req *rq,
227227
erofs_err(rq->sb, "failed to decompress %d in[%u, %u] out[%u]",
228228
ret, rq->inputsize, inputmargin, rq->outputsize);
229229

230-
WARN_ON(1);
231230
print_hex_dump(KERN_DEBUG, "[ in]: ", DUMP_PREFIX_OFFSET,
232231
16, 1, src + inputmargin, rq->inputsize, true);
233232
print_hex_dump(KERN_DEBUG, "[out]: ", DUMP_PREFIX_OFFSET,

0 commit comments

Comments
 (0)