提交 02ace2cd 编写于 作者: S Simon Glass 提交者: Tom Rini

image: Update zstd to avoid reporting error twice

The zstd implementation prints the error in image_decomp() which is
incorrect and does not match other algorithms. Drop this and let the
caller report the error.
Signed-off-by: NSimon Glass <sjg@chromium.org>
上级 b876eb87
......@@ -534,12 +534,10 @@ int image_decomp(int comp, ulong load, ulong image_start, int type,
abuf_init_set(&in, image_buf, image_len);
abuf_init_set(&in, load_buf, unc_len);
ret = zstd_decompress(&in, &out);
if (ret < 0) {
printf("ZSTD decompression failed\n");
return ret;
if (ret >= 0) {
image_len = ret;
ret = 0;
}
image_len = ret;
break;
}
#endif /* CONFIG_ZSTD */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册