spapr: fix possible memory leak
get_boot_devices_list() will malloc memory, spapr_finalize_fdt doesn't free it. Signed-off-by: Chenliang <chenliang88@huawei.com> Signed-off-by: Gonglei <arei.gonglei@huawei.com> Signed-off-by: Alexander Graf <agraf@suse.de>
This commit is contained in:
parent
261265cc91
commit
a21a7a7012
|
@ -783,6 +783,7 @@ static void spapr_finalize_fdt(sPAPREnvironment *spapr,
|
||||||
|
|
||||||
cpu_physical_memory_write(fdt_addr, fdt, fdt_totalsize(fdt));
|
cpu_physical_memory_write(fdt_addr, fdt, fdt_totalsize(fdt));
|
||||||
|
|
||||||
|
g_free(bootlist);
|
||||||
g_free(fdt);
|
g_free(fdt);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue