summaryrefslogtreecommitdiff
path: root/HTMLparser.c
diff options
context:
space:
mode:
authorMike Hommey <mh@glandium.org>2004-05-17 06:56:59 +0000
committerMike Hommey <mh@glandium.org>2004-05-17 06:56:59 +0000
commitd4e028c96af89ade493b440d4f2de6b684c03a06 (patch)
tree4b74b3cd4b14524309bc5a3e776d81d4bbc5efe4 /HTMLparser.c
parent81bcf076ea11e114a60e429338a15748066de163 (diff)
downloadlibxml2-d4e028c96af89ade493b440d4f2de6b684c03a06.tar.gz
Load /tmp/tmp.QVLX5b/libxml2-2.6.10 intoupstream/2.6.10
packages/libxml2/branches/upstream/current.
Diffstat (limited to 'HTMLparser.c')
-rw-r--r--HTMLparser.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/HTMLparser.c b/HTMLparser.c
index bf671a1..2e7984d 100644
--- a/HTMLparser.c
+++ b/HTMLparser.c
@@ -2027,6 +2027,8 @@ static int areBlanks(htmlParserCtxtPtr ctxt, const xmlChar *str, int len) {
return(1);
if (ctxt->node == NULL) return(0);
lastChild = xmlGetLastChild(ctxt->node);
+ while ((lastChild) && (lastChild->type == XML_COMMENT_NODE))
+ lastChild = lastChild->prev;
if (lastChild == NULL) {
if ((ctxt->node->type != XML_ELEMENT_NODE) &&
(ctxt->node->content != NULL)) return(0);