mirror of https://github.com/xemu-project/xemu.git
ppc/pnv: fix pnv_core_realize() error handling
commit d35aefa9ae
("ppc/pnv: introduce a new intc_create() operation
to the chip model") changed the object link in the pnv_core_realize()
routine but a return was forgotten in case of error, which can lead to
more problems afterwards (segv)
Signed-off-by: Cédric Le Goater <clg@kaod.org>
Reviewed-by: Greg Kurz <groug@kaod.org>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
parent
abe82ebb20
commit
56f6843921
|
@ -150,6 +150,7 @@ static void pnv_core_realize(DeviceState *dev, Error **errp)
|
|||
if (!chip) {
|
||||
error_propagate(errp, local_err);
|
||||
error_prepend(errp, "required link 'chip' not found: ");
|
||||
return;
|
||||
}
|
||||
|
||||
pc->threads = g_new(PowerPCCPU *, cc->nr_threads);
|
||||
|
|
Loading…
Reference in New Issue