From bc09a287d85505eabd1f548eae3a188ece902e49 Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Tue, 10 Feb 2015 15:11:17 +0100 Subject: [PATCH] tpm: Avoid qerror_report_err() outside QMP command handlers qerror_report_err() is a transitional interface to help with converting existing monitor commands to QMP. It should not be used elsewhere. Replace by error_report_err() in initial startup helper configure_tpm(). Signed-off-by: Markus Armbruster Reviewed-by: Eric Blake --- tpm.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/tpm.c b/tpm.c index c371023b1c..4ffd9b927e 100644 --- a/tpm.c +++ b/tpm.c @@ -162,8 +162,7 @@ static int configure_tpm(QemuOpts *opts) /* validate backend specific opts */ qemu_opts_validate(opts, be->opts, &local_err); if (local_err) { - qerror_report_err(local_err); - error_free(local_err); + error_report_err(local_err); return 1; } @@ -174,8 +173,7 @@ static int configure_tpm(QemuOpts *opts) tpm_backend_open(drv, &local_err); if (local_err) { - qerror_report_err(local_err); - error_free(local_err); + error_report_err(local_err); return 1; }