mirror of
https://github.com/xemu-project/xemu.git
synced 2024-11-23 11:39:53 +00:00
qdev: Move error printing to the end of qdev_device_help()
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> Signed-off-by: Andreas Färber <afaerber@suse.de>
This commit is contained in:
parent
43c95d782d
commit
5185f0e0a6
@ -245,9 +245,7 @@ int qdev_device_help(QemuOpts *opts)
|
||||
|
||||
prop_list = qmp_device_list_properties(driver, &local_err);
|
||||
if (local_err) {
|
||||
error_printf("%s\n", error_get_pretty(local_err));
|
||||
error_free(local_err);
|
||||
return 1;
|
||||
goto error;
|
||||
}
|
||||
|
||||
for (prop = prop_list; prop; prop = prop->next) {
|
||||
@ -263,6 +261,11 @@ int qdev_device_help(QemuOpts *opts)
|
||||
|
||||
qapi_free_DevicePropertyInfoList(prop_list);
|
||||
return 1;
|
||||
|
||||
error:
|
||||
error_printf("%s\n", error_get_pretty(local_err));
|
||||
error_free(local_err);
|
||||
return 1;
|
||||
}
|
||||
|
||||
static Object *qdev_get_peripheral(void)
|
||||
|
Loading…
Reference in New Issue
Block a user