This is a continuation of the work started in commit 565f65d27: "error: Use error_report_err() where appropriate"
Signed-off-by: zhanghailiang <zhang.zhanghaili...@huawei.com> Reviewed-by: Eric Blake <ebl...@redhat.com> --- v2: - Add Reviewd-by and commit message --- hw/arm/virt.c | 2 +- savevm.c | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 69f51ac..4732c12 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -768,7 +768,7 @@ static void machvirt_init(MachineState *machine) /* Handle any CPU options specified by the user */ cc->parse_features(CPU(cpuobj), cpustr[1], &err); if (err) { - error_report("%s", error_get_pretty(err)); + error_report_err(err); exit(1); } diff --git a/savevm.c b/savevm.c index ce2b6a2..c4f8c39 100644 --- a/savevm.c +++ b/savevm.c @@ -932,8 +932,7 @@ int qemu_loadvm_state(QEMUFile *f) int ret; if (qemu_savevm_state_blocked(&local_err)) { - error_report("%s", error_get_pretty(local_err)); - error_free(local_err); + error_report_err(local_err); return -EINVAL; } -- 1.7.12.4