summaryrefslogtreecommitdiffstats
path: root/arch/arm/boot/compressed/decompress.c
diff options
context:
space:
mode:
authorNicolas Pitre <nicolas.pitre@linaro.org>2011-04-21 21:59:49 -0400
committerNicolas Pitre <nico@fluxnic.net>2011-05-07 00:08:01 -0400
commitccc1c7c6c25661f0071a7ebe997abcbf529df3e9 (patch)
treea879518e3e9d70521d0ac1103ec3bbbd2a2b7aba /arch/arm/boot/compressed/decompress.c
parente40f1e9fb342a2e38fae164861a8cff248ceb87b (diff)
ARM: zImage: don't ignore error returned from decompress()
If decompress() returns an error without calling error(), we must not attempt to boot the resulting kernel. Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org> Tested-by: Shawn Guo <shawn.guo@linaro.org> Tested-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm/boot/compressed/decompress.c')
-rw-r--r--arch/arm/boot/compressed/decompress.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/arm/boot/compressed/decompress.c b/arch/arm/boot/compressed/decompress.c
index 4c72a97bc3e..07be5a2f830 100644
--- a/arch/arm/boot/compressed/decompress.c
+++ b/arch/arm/boot/compressed/decompress.c
@@ -44,7 +44,7 @@ extern void error(char *);
#include "../../../../lib/decompress_unlzma.c"
#endif
-void do_decompress(u8 *input, int len, u8 *output, void (*error)(char *x))
+int do_decompress(u8 *input, int len, u8 *output, void (*error)(char *x))
{
- decompress(input, len, NULL, NULL, output, NULL, error);
+ return decompress(input, len, NULL, NULL, output, NULL, error);
}