}
prss_parse_doc(data, doc);
+ xmlFreeDoc(doc);
}
void prss_free(PRSS *data)
if (!data) {
return;
}
- xmlFreeDoc(data->_data);
free(data->version);
free(data->items);
}
void prss_parse_doc(PRSS *result, xmlDocPtr doc)
{
- /* FIXME: doc shouldn't be freed after failure when called explicitly from
- * program! */
-
xmlNodePtr root = xmlDocGetRootElement(doc);
prss_null(result);
- result->_data = doc;
do {
if (root->type == XML_ELEMENT_NODE) {
if (!strcmp((const char *) root->name, "RDF")) {