diff options
author | nicolas.zilio@hotmail.fr <> | 2015-09-15 11:36:20 +0200 |
---|---|---|
committer | nicolas.zilio@hotmail.fr <> | 2015-09-15 11:36:20 +0200 |
commit | c71075ca84d896c650dd0b65c7664149ed51dcec (patch) | |
tree | 9e1652e78bcd9a34770dd26d9c5477a965377cd0 /pcilib/xml.c | |
parent | 6a8b4a516689daa34951ccca841c2a4f57412b0e (diff) | |
download | pcitool-c71075ca84d896c650dd0b65c7664149ed51dcec.tar.gz pcitool-c71075ca84d896c650dd0b65c7664149ed51dcec.tar.bz2 pcitool-c71075ca84d896c650dd0b65c7664149ed51dcec.tar.xz pcitool-c71075ca84d896c650dd0b65c7664149ed51dcec.zip |
addition of other remarks, cleaning in progress
Diffstat (limited to 'pcilib/xml.c')
-rw-r--r-- | pcilib/xml.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/pcilib/xml.c b/pcilib/xml.c index fe25cf7..5be5abd 100644 --- a/pcilib/xml.c +++ b/pcilib/xml.c @@ -138,6 +138,7 @@ pcilib_get_associated_views(pcilib_t* ctx, const char* reg_name,xmlXPathContextP } xmlXPathFreeObject(nodes); + free(path); return 0; } @@ -507,7 +508,6 @@ pcilib_xml_create_unit(pcilib_t *ctx, xmlXPathContextPtr xpath, xmlDocPtr doc, x attr=node->properties; value=(char*)attr->children->content; desc.name=value; - desc.other_units=malloc(sizeof(pcilib_transform_unit_t)); for (cur = node->children; cur != NULL; cur = cur->next) { if (!cur->children) continue; @@ -520,7 +520,6 @@ pcilib_xml_create_unit(pcilib_t *ctx, xmlXPathContextPtr xpath, xmlDocPtr doc, x if (!value || !attr) continue; if (!strcasecmp(name, "convert_unit")) { - desc.other_units=realloc(desc.other_units,(i+1)*sizeof(pcilib_transform_unit_t)); desc.other_units[i].name=value2; desc.other_units[i].transform_formula=value; i++; |