Fix ref leak in error case

This commit is contained in:
John-Mark Bell 2012-07-22 13:49:10 +01:00
parent 65ea98ba60
commit 41abc08cbb

View File

@ -292,12 +292,14 @@ void html_finish_conversion(html_content *c)
}
if (xml_to_box(html, c, html_box_convert_done) == false) {
dom_node_unref(html);
html_destroy_objects(c);
msg_data.error = messages_get("NoMemory");
content_broadcast(&c->base, CONTENT_MSG_ERROR, msg_data);
content_set_error(&c->base);
return;
}
dom_node_unref(html);
}