aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--hmp.c2
-rw-r--r--target/i386/monitor.c2
2 files changed, 3 insertions, 1 deletions
diff --git a/hmp.c b/hmp.c
index a277517625..679467d85a 100644
--- a/hmp.c
+++ b/hmp.c
@@ -1321,7 +1321,7 @@ void hmp_savevm(Monitor *mon, const QDict *qdict)
void hmp_delvm(Monitor *mon, const QDict *qdict)
{
BlockDriverState *bs;
- Error *err;
+ Error *err = NULL;
const char *name = qdict_get_str(qdict, "name");
if (bdrv_all_delete_snapshot(name, &bs, &err) < 0) {
diff --git a/target/i386/monitor.c b/target/i386/monitor.c
index 011419eba2..a890b3c2ab 100644
--- a/target/i386/monitor.c
+++ b/target/i386/monitor.c
@@ -696,6 +696,8 @@ void hmp_info_sev(Monitor *mon, const QDict *qdict)
} else {
monitor_printf(mon, "SEV is not enabled\n");
}
+
+ qapi_free_SevInfo(info);
}
SevLaunchMeasureInfo *qmp_query_sev_launch_measure(Error **errp)