[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-stable] [PATCH] fixup! qom: Avoid unvisited 'id'/'qom-type' in use
From: |
Eric Blake |
Subject: |
[Qemu-stable] [PATCH] fixup! qom: Avoid unvisited 'id'/'qom-type' in user_creatable_add_opts |
Date: |
Wed, 22 Mar 2017 12:30:23 -0500 |
CC: address@hidden
Signed-off-by: Eric Blake <address@hidden>
---
Markus already issued the pull request, so if that goes in before
he can squash this for a v2, then I'll have to turn this into a
full-blown patch.
v3.5: avoid memory leak when id is not present
v3: enhance commit message
v2: new patch
---
qom/object_interfaces.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/qom/object_interfaces.c b/qom/object_interfaces.c
index cc9a694..9c271ad 100644
--- a/qom/object_interfaces.c
+++ b/qom/object_interfaces.c
@@ -122,6 +122,7 @@ Object *user_creatable_add_opts(QemuOpts *opts, Error
**errp)
}
if (!id) {
error_setg(errp, QERR_MISSING_PARAMETER, "id");
+ g_free(type);
return NULL;
}
--
2.9.3
- [Qemu-stable] [PATCH] fixup! qom: Avoid unvisited 'id'/'qom-type' in user_creatable_add_opts,
Eric Blake <=