aboutsummaryrefslogtreecommitdiff
path: root/hw/mem
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2020-05-05 12:18:59 +0200
committerMarkus Armbruster <armbru@redhat.com>2020-05-27 07:44:59 +0200
commit75de4efa00d2e3df5abfd6b35fc5b04e98443dd2 (patch)
tree6bd59de247961afd43189b397340096f1d3807ab /hw/mem
parentddc760832fa8cf5e93b9d9e6e854a5114ac63510 (diff)
downloadqemu-75de4efa00d2e3df5abfd6b35fc5b04e98443dd2.zip
qemu-75de4efa00d2e3df5abfd6b35fc5b04e98443dd2.tar.gz
qemu-75de4efa00d2e3df5abfd6b35fc5b04e98443dd2.tar.bz2
nvdimm: Plug memory leak in uuid property setter
nvdimm_set_uuid() leaks memory on qemu_uuid_parse() failure. Fix that. Fixes: 6c5627bb24dcd68c997857a8b671617333b1289f Cc: Xiao Guangrong <xiaoguangrong.eric@gmail.com> Cc: Shivaprasad G Bhat <sbhat@linux.ibm.com> Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20200505101908.6207-2-armbru@redhat.com> Tested-by: Shivaprasad G Bhat <sbhat@linux.ibm.com> Reviewed-by: Shivaprasad G Bhat <sbhat@linux.ibm.com>
Diffstat (limited to 'hw/mem')
-rw-r--r--hw/mem/nvdimm.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/hw/mem/nvdimm.c b/hw/mem/nvdimm.c
index c5adedc..76f66e0 100644
--- a/hw/mem/nvdimm.c
+++ b/hw/mem/nvdimm.c
@@ -97,7 +97,6 @@ static void nvdimm_set_uuid(Object *obj, Visitor *v, const char *name,
if (qemu_uuid_parse(value, &nvdimm->uuid) != 0) {
error_setg(errp, "Property '%s.%s' has invalid value",
object_get_typename(obj), name);
- goto out;
}
g_free(value);