mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-22 03:12:22 +00:00
virDomainDefParseXML: Free @tmp when parsing genid
We need to free return value of virXPathString(). ==12962== 37 bytes in 1 blocks are definitely lost in loss record 156 of 331 ==12962== at 0x4C2AF0F: malloc (vg_replace_malloc.c:299) ==12962== by 0x91E8439: strdup (in /lib64/libc-2.25.so) ==12962== by 0x5DBD551: virStrdup (virstring.c:977) ==12962== by 0x5DD3E5E: virXPathString (virxml.c:84) ==12962== by 0x5E178AB: virDomainDefParseXML (domain_conf.c:19110) ==12962== by 0x5E1E985: virDomainDefParseNode (domain_conf.c:20885) ==12962== by 0x5E1E7CB: virDomainDefParse (domain_conf.c:20827) ==12962== by 0x5E1E871: virDomainDefParseFile (domain_conf.c:20853) Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
f8466296e4
commit
5f18b9ba8d
@ -19120,6 +19120,7 @@ virDomainDefParseXML(xmlDocPtr xml,
|
||||
"%s", _("malformed genid element"));
|
||||
goto error;
|
||||
}
|
||||
VIR_FREE(tmp);
|
||||
}
|
||||
}
|
||||
VIR_FREE(nodes);
|
||||
|
Loading…
x
Reference in New Issue
Block a user