diff options
author | Daniel Veillard <veillard@src.gnome.org> | 2005-07-06 15:17:38 +0000 |
---|---|---|
committer | Daniel Veillard <veillard@src.gnome.org> | 2005-07-06 15:17:38 +0000 |
commit | abac41e829e0f75eb78be148b24438ddd607676c (patch) | |
tree | 5ecf1c193190c7e198afc1360241cee805fe0c8f | |
parent | 6d30ff2c08b381cff003eead71bf1321a0c0feea (diff) | |
download | android_external_libxml2-abac41e829e0f75eb78be148b24438ddd607676c.tar.gz android_external_libxml2-abac41e829e0f75eb78be148b24438ddd607676c.tar.bz2 android_external_libxml2-abac41e829e0f75eb78be148b24438ddd607676c.zip |
fixing bug #166777 (and #169838), it was an heuristic in areBlanks which
* parser.c: fixing bug #166777 (and #169838), it was an heuristic
in areBlanks which failed.
* result/winblanks.xml* result/noent/winblanks.xml test/winblanks.xml:
added the input file to the regression tests
Daniel
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | parser.c | 2 | ||||
-rw-r--r-- | result/noent/winblanks.xml | 6 | ||||
-rw-r--r-- | result/winblanks.xml | 6 | ||||
-rw-r--r-- | result/winblanks.xml.rde | 13 | ||||
-rw-r--r-- | result/winblanks.xml.rdr | 13 | ||||
-rw-r--r-- | result/winblanks.xml.sax | 18 | ||||
-rw-r--r-- | result/winblanks.xml.sax2 | 18 | ||||
-rw-r--r-- | test/winblanks.xml | 5 |
9 files changed, 87 insertions, 1 deletions
@@ -1,3 +1,10 @@ +Wed Jul 6 17:14:03 CEST 2005 Daniel Veillard <daniel@veillard.com> + + * parser.c: fixing bug #166777 (and #169838), it was an heuristic + in areBlanks which failed. + * result/winblanks.xml* result/noent/winblanks.xml test/winblanks.xml: + added the input file to the regression tests + Wed Jul 6 13:40:22 CEST 2005 Kasimier Buchcik <libxml2-cvs@cazic.net> * xmlschemastypes.c: Fixed bug #309338, reported by Kupriyanov @@ -2142,7 +2142,7 @@ static int areBlanks(xmlParserCtxtPtr ctxt, const xmlChar *str, int len, /* * Otherwise, heuristic :-\ */ - if (RAW != '<') return(0); + if ((RAW != '<') && (RAW != 0xD)) return(0); if ((ctxt->node->children == NULL) && (RAW == '<') && (NXT(1) == '/')) return(0); diff --git a/result/noent/winblanks.xml b/result/noent/winblanks.xml new file mode 100644 index 00000000..0044aa2c --- /dev/null +++ b/result/noent/winblanks.xml @@ -0,0 +1,6 @@ +<?xml version="1.0"?> +<a> + <B> + <C/> +</B> +</a> diff --git a/result/winblanks.xml b/result/winblanks.xml new file mode 100644 index 00000000..0044aa2c --- /dev/null +++ b/result/winblanks.xml @@ -0,0 +1,6 @@ +<?xml version="1.0"?> +<a> + <B> + <C/> +</B> +</a> diff --git a/result/winblanks.xml.rde b/result/winblanks.xml.rde new file mode 100644 index 00000000..2f6a5d39 --- /dev/null +++ b/result/winblanks.xml.rde @@ -0,0 +1,13 @@ +0 1 a 0 0 +1 14 #text 0 1 + +1 1 B 0 0 +2 14 #text 0 1 + +2 1 C 1 0 +2 14 #text 0 1 + +1 15 B 0 0 +1 14 #text 0 1 + +0 15 a 0 0 diff --git a/result/winblanks.xml.rdr b/result/winblanks.xml.rdr new file mode 100644 index 00000000..2f6a5d39 --- /dev/null +++ b/result/winblanks.xml.rdr @@ -0,0 +1,13 @@ +0 1 a 0 0 +1 14 #text 0 1 + +1 1 B 0 0 +2 14 #text 0 1 + +2 1 C 1 0 +2 14 #text 0 1 + +1 15 B 0 0 +1 14 #text 0 1 + +0 15 a 0 0 diff --git a/result/winblanks.xml.sax b/result/winblanks.xml.sax new file mode 100644 index 00000000..72e39d55 --- /dev/null +++ b/result/winblanks.xml.sax @@ -0,0 +1,18 @@ +SAX.setDocumentLocator() +SAX.startDocument() +SAX.startElement(a) +SAX.characters( + , 5) +SAX.startElement(B) +SAX.characters( + , 9) +SAX.startElement(C) +SAX.endElement(C) +SAX.characters( , 3) +SAX.characters( +, 1) +SAX.endElement(B) +SAX.characters( +, 1) +SAX.endElement(a) +SAX.endDocument() diff --git a/result/winblanks.xml.sax2 b/result/winblanks.xml.sax2 new file mode 100644 index 00000000..6e9d693f --- /dev/null +++ b/result/winblanks.xml.sax2 @@ -0,0 +1,18 @@ +SAX.setDocumentLocator() +SAX.startDocument() +SAX.startElementNs(a, NULL, NULL, 0, 0, 0) +SAX.characters( + , 5) +SAX.startElementNs(B, NULL, NULL, 0, 0, 0) +SAX.characters( + , 9) +SAX.startElementNs(C, NULL, NULL, 0, 0, 0) +SAX.endElementNs(C, NULL, NULL) +SAX.characters( , 3) +SAX.characters( +, 1) +SAX.endElementNs(B, NULL, NULL) +SAX.characters( +, 1) +SAX.endElementNs(a, NULL, NULL) +SAX.endDocument() diff --git a/test/winblanks.xml b/test/winblanks.xml new file mode 100644 index 00000000..8f937f29 --- /dev/null +++ b/test/winblanks.xml @@ -0,0 +1,5 @@ +<a>
+ <B>
+ <C/>
+</B>
+</a>
\ No newline at end of file |