The intention of this code was to check the return value of fdt_open_into. Fix this. Signed-off-by: Steffen Trumtrar <s.trumtrar@xxxxxxxxxxxxxx> --- commands/bootm.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/commands/bootm.c b/commands/bootm.c index 1e1dc52..4f4cbb3 100644 --- a/commands/bootm.c +++ b/commands/bootm.c @@ -202,10 +202,9 @@ static int bootm_open_oftree(struct image_data *data, char *oftree, int num) } fdt = xrealloc(fdt, size + 0x8000); - fdt_open_into(fdt, fdt, size + 0x8000); - - if (!fdt) { - printf("unable to read %s\n", oftree); + ret = fdt_open_into(fdt, fdt, size + 0x8000); + if (ret) { + printf("unable to parse %s\n", oftree); return -ENODEV; } -- 1.7.10 _______________________________________________ barebox mailing list barebox@xxxxxxxxxxxxxxxxxxx http://lists.infradead.org/mailman/listinfo/barebox