summaryrefslogtreecommitdiff
path: root/migration/qjson.h
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2019-09-12 16:25:09 +0400
committerDr. David Alan Gilbert <dgilbert@redhat.com>2019-09-25 15:51:19 +0100
commit91490583f3cc8613159008502decf2f1481508fd (patch)
tree24cc8718f2cc29dd0c90f7ecf2263d8cd39b8a2f /migration/qjson.h
parent240ab11fb72049d6373cbbec8d788f8e411a00bc (diff)
downloadqemu-91490583f3cc8613159008502decf2f1481508fd.zip
migration: fix vmdesc leak on vmstate_save() error
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Message-Id: <20190912122514.22504-2-marcandre.lureau@redhat.com> Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Reviewed-by: Daniel P. Berrangé <berrange@redhat.com> Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Diffstat (limited to 'migration/qjson.h')
-rw-r--r--migration/qjson.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/migration/qjson.h b/migration/qjson.h
index 41664f2d71..1786bb5864 100644
--- a/migration/qjson.h
+++ b/migration/qjson.h
@@ -24,4 +24,6 @@ void json_start_object(QJSON *json, const char *name);
const char *qjson_get_str(QJSON *json);
void qjson_finish(QJSON *json);
+G_DEFINE_AUTOPTR_CLEANUP_FUNC(QJSON, qjson_destroy)
+
#endif /* QEMU_QJSON_H */