From: Lasse Collin Date: Thu, 13 Jan 2011 01:01:18 +0000 (-0800) Subject: Decompressors: check for write errors in decompress_unlzma.c X-Git-Tag: v2.6.38-rc1~257 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=528941ca05734f24a7568c1c082125f2b635c4eb;p=pandora-kernel.git Decompressors: check for write errors in decompress_unlzma.c The return value of wr->flush() is not checked in write_byte(). This means that the decompressor won't stop even if the caller doesn't want more data. This can happen e.g. with corrupt LZMA-compressed initramfs. Returning the error quickly allows the user to see the error message quicker. There is a similar missing check for wr.flush() near the end of unlzma(). Signed-off-by: Lasse Collin Cc: "H. Peter Anvin" Cc: Alain Knaff Cc: Albin Tonnerre Cc: Phillip Lougher Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed