X-Git-Url: http://git.openwrt.org/?p=openwrt%2Fsvn-archive%2Farchive.git;a=blobdiff_plain;f=target%2Flinux%2Fadm5120-2.6%2Fimage%2Flzma-loader%2Fsrc%2Fdecompress.c;h=ffc87ee0db56a3bd4e03a4757e97cdb014ef9314;hp=f867e20dc5110f51d088e62a4f7e98ebd4fbeb2c;hb=5cf10e99cf408672f78664e37646e2192f9a7fe6;hpb=b8be2ca73e6f1dc13acf43c14d8ecaa3a761d385;ds=sidebyside diff --git a/target/linux/adm5120-2.6/image/lzma-loader/src/decompress.c b/target/linux/adm5120-2.6/image/lzma-loader/src/decompress.c index f867e20dc5..ffc87ee0db 100644 --- a/target/linux/adm5120-2.6/image/lzma-loader/src/decompress.c +++ b/target/linux/adm5120-2.6/image/lzma-loader/src/decompress.c @@ -277,9 +277,20 @@ void decompress_entry(unsigned long reg_a0, unsigned long reg_a1, (unsigned char*)LOADADDR, osize, &i); #endif if (res != LZMA_RESULT_OK) { - print_str("failed, LzmaDecode error: "); - print_hex(res); - print_str("\n"); + print_str("failed!\n"); + print_str("LzmaDecode: "); + switch (res) { + case LZMA_RESULT_DATA_ERROR: + print_str("data error\n"); + break; + case LZMA_RESULT_NOT_ENOUGH_MEM: + print_str("not enough memory\n"); + break; + default: + print_str("unknown error, err=0x"); + print_hex(res); + print_str("\n"); + } halt(); }