summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--render/html.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/render/html.c b/render/html.c
index 7db9164a3..cbda8682d 100644
--- a/render/html.c
+++ b/render/html.c
@@ -570,11 +570,8 @@ bool html_head(struct content *c, xmlNode *head)
xmlNode *node;
xmlChar *s;
- for (node = head->children; node != 0; node = node->next) {
- if (node->type != XML_ELEMENT_NODE)
- continue;
-
- LOG(("Node: %s", node->name));
+ for (node = xmlFirstElementChild(head); node != 0;
+ node = xmlNextElementSibling(node)) {
if (c->title == NULL && strcmp((const char *) node->name,
"title") == 0) {
xmlChar *title = xmlNodeGetContent(node);