mirror of
https://gitlab.gnome.org/GNOME/libxml2
synced 2025-03-28 21:33:13 +00:00
fixed a problem in push mode when attribute contains unescaped '>'
* parser.c: fixed a problem in push mode when attribute contains unescaped '>' characters, fixes bug #134566 * test/att6 result//att6*: added the test to the regression suite Daniel
This commit is contained in:
parent
965983a5d5
commit
b37440047e
@ -1,3 +1,9 @@
|
|||||||
|
Wed Feb 18 15:20:42 CET 2004 Daniel Veillard <daniel@veillard.com>
|
||||||
|
|
||||||
|
* parser.c: fixed a problem in push mode when attribute contains
|
||||||
|
unescaped '>' characters, fixes bug #134566
|
||||||
|
* test/att6 result//att6*: added the test to the regression suite
|
||||||
|
|
||||||
Tue Feb 17 17:26:31 CET 2004 Daniel Veillard <daniel@veillard.com>
|
Tue Feb 17 17:26:31 CET 2004 Daniel Veillard <daniel@veillard.com>
|
||||||
|
|
||||||
* valid.c: removing a non-linear behaviour from ID/IDREF raised
|
* valid.c: removing a non-linear behaviour from ID/IDREF raised
|
||||||
|
3
parser.c
3
parser.c
@ -9030,7 +9030,8 @@ xmlParseTryOrFinish(xmlParserCtxtPtr ctxt, int terminate) {
|
|||||||
}
|
}
|
||||||
if (!terminate) {
|
if (!terminate) {
|
||||||
if (ctxt->progressive) {
|
if (ctxt->progressive) {
|
||||||
if ((lastgt == NULL) || (ctxt->input->cur > lastgt))
|
/* > can be found unescaped in attribute values */
|
||||||
|
if ((lastlt == NULL) || (ctxt->input->cur >= lastlt))
|
||||||
goto done;
|
goto done;
|
||||||
} else if (xmlParseLookupSequence(ctxt, '>', 0, 0) < 0) {
|
} else if (xmlParseLookupSequence(ctxt, '>', 0, 0) < 0) {
|
||||||
goto done;
|
goto done;
|
||||||
|
6
result/att6
Normal file
6
result/att6
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<Invoice xmlns:ccts="urn:oasis:names:tc:ubl:CoreComponentParameters:1.0:0.70" xmlns:cct="urn:oasis:names:tc:ubl:CoreComponentTypes:1.0:0.70" xmlns:cat="urn:oasis:names:tc:ubl:CommonAggregateTypes:1.0:0.70" xmlns="urn:oasis:names:tc:ubl:Invoice:1.0:0.70">
|
||||||
|
<cat:ReferencedOrder>
|
||||||
|
<cat:SellersOrderID schemeID="pvalue->ReferencedOrder.SellersOrderID.schemeID" schemeAgencyID="pvalue->ReferencedOrder.SellersOrderID.schemeAgencyID" schemeVersionID="pvalue->ReferencedOrder.SellersOrderID.schemeVersionID" schemeAgencySchemeID="pvalue->ReferencedOrder.SellersOrderID.schemeAgencySchemeID" schemeAgencySchemeAgencyID="pvalue->ReferencedOrder.SellersOrderID.schemeAgencySchemeAgencyID" schemeDataURI="pvalue->ReferencedOrder.SellersOrderID.schemeDataURI" schemeURI="pvalue->ReferencedOrder.SellersOrderID.schemeURI" UID="pvalue->ReferencedOrder.SellersOrderID.UID" UIDRef="pvalue->ReferencedOrder.SellersOrderID.UIDRef" UIDRefs="pvalue->ReferencedOrder.SellersOrderID.UIDRefs0" language="pvalue->ReferencedOrder.SellersOrderID.language">pvalue->ReferencedOrder.SellersOrderID</cat:SellersOrderID>
|
||||||
|
</cat:ReferencedOrder>
|
||||||
|
</Invoice>
|
15
result/att6.rdr
Normal file
15
result/att6.rdr
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
0 1 Invoice 0 0
|
||||||
|
1 14 #text 0 1
|
||||||
|
|
||||||
|
1 1 cat:ReferencedOrder 0 0
|
||||||
|
2 14 #text 0 1
|
||||||
|
|
||||||
|
2 1 cat:SellersOrderID 0 0
|
||||||
|
3 3 #text 0 1 pvalue->ReferencedOrder.SellersOrderID
|
||||||
|
2 15 cat:SellersOrderID 0 0
|
||||||
|
2 14 #text 0 1
|
||||||
|
|
||||||
|
1 15 cat:ReferencedOrder 0 0
|
||||||
|
1 14 #text 0 1
|
||||||
|
|
||||||
|
0 15 Invoice 0 0
|
22
result/att6.sax
Normal file
22
result/att6.sax
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
SAX.setDocumentLocator()
|
||||||
|
SAX.startDocument()
|
||||||
|
SAX.startElement(Invoice, xmlns:ccts='urn:oasis:names:tc:ubl:CoreComponentParameters:1.0:0.70', xmlns:cct='urn:oasis:names:tc:ubl:CoreComponentTypes:1.0:0.70', xmlns:cat='urn:oasis:names:tc:ubl:CommonAggregateTypes:1.0:0.70', xmlns='urn:oasis:names:tc:ubl:Invoice:1.0:0.70')
|
||||||
|
SAX.characters(
|
||||||
|
, 4)
|
||||||
|
SAX.startElement(cat:ReferencedOrder)
|
||||||
|
SAX.characters(
|
||||||
|
, 7)
|
||||||
|
SAX.getEntity(gt)
|
||||||
|
SAX.startElement(cat:SellersOrderID, schemeID='pvalue->ReferencedOrder.SellersOrderID.schemeID', schemeAgencyID='pvalue->ReferencedOrder.SellersOrderID.schemeAgencyID', schemeVersionID='pvalue->ReferencedOrder.SellersOrderID.schemeVersionID', schemeAgencySchemeID='pvalue->ReferencedOrder.SellersOrderID.schemeAgencySchemeID', schemeAgencySchemeAgencyID='pvalue->ReferencedOrder.SellersOrderID.schemeAgencySchemeAgencyID', schemeDataURI='pvalue->ReferencedOrder.SellersOrderID.schemeDataURI', schemeURI='pvalue->ReferencedOrder.SellersOrderID.schemeURI', UID='pvalue->ReferencedOrder.SellersOrderID.UID', UIDRef='pvalue->ReferencedOrder.SellersOrderID.UIDRef', UIDRefs='pvalue->ReferencedOrder.SellersOrderID.UIDRefs0', language='pvalue->ReferencedOrder.SellersOrderID.language')
|
||||||
|
SAX.characters(pvalue-, 7)
|
||||||
|
SAX.getEntity(gt)
|
||||||
|
SAX.characters(>, 1)
|
||||||
|
SAX.characters(ReferencedOrder.SellersOrderID, 30)
|
||||||
|
SAX.endElement(cat:SellersOrderID)
|
||||||
|
SAX.characters(
|
||||||
|
, 4)
|
||||||
|
SAX.endElement(cat:ReferencedOrder)
|
||||||
|
SAX.characters(
|
||||||
|
, 1)
|
||||||
|
SAX.endElement(Invoice)
|
||||||
|
SAX.endDocument()
|
6
result/noent/att6
Normal file
6
result/noent/att6
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<Invoice xmlns:ccts="urn:oasis:names:tc:ubl:CoreComponentParameters:1.0:0.70" xmlns:cct="urn:oasis:names:tc:ubl:CoreComponentTypes:1.0:0.70" xmlns:cat="urn:oasis:names:tc:ubl:CommonAggregateTypes:1.0:0.70" xmlns="urn:oasis:names:tc:ubl:Invoice:1.0:0.70">
|
||||||
|
<cat:ReferencedOrder>
|
||||||
|
<cat:SellersOrderID schemeID="pvalue->ReferencedOrder.SellersOrderID.schemeID" schemeAgencyID="pvalue->ReferencedOrder.SellersOrderID.schemeAgencyID" schemeVersionID="pvalue->ReferencedOrder.SellersOrderID.schemeVersionID" schemeAgencySchemeID="pvalue->ReferencedOrder.SellersOrderID.schemeAgencySchemeID" schemeAgencySchemeAgencyID="pvalue->ReferencedOrder.SellersOrderID.schemeAgencySchemeAgencyID" schemeDataURI="pvalue->ReferencedOrder.SellersOrderID.schemeDataURI" schemeURI="pvalue->ReferencedOrder.SellersOrderID.schemeURI" UID="pvalue->ReferencedOrder.SellersOrderID.UID" UIDRef="pvalue->ReferencedOrder.SellersOrderID.UIDRef" UIDRefs="pvalue->ReferencedOrder.SellersOrderID.UIDRefs0" language="pvalue->ReferencedOrder.SellersOrderID.language">pvalue->ReferencedOrder.SellersOrderID</cat:SellersOrderID>
|
||||||
|
</cat:ReferencedOrder>
|
||||||
|
</Invoice>
|
6
test/att6
Normal file
6
test/att6
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<Invoice xmlns:ccts="urn:oasis:names:tc:ubl:CoreComponentParameters:1.0:0.70" xmlns:cct="urn:oasis:names:tc:ubl:CoreComponentTypes:1.0:0.70" xmlns:cat="urn:oasis:names:tc:ubl:CommonAggregateTypes:1.0:0.70" xmlns="urn:oasis:names:tc:ubl:Invoice:1.0:0.70">
|
||||||
|
<cat:ReferencedOrder>
|
||||||
|
<cat:SellersOrderID schemeID="pvalue->ReferencedOrder.SellersOrderID.schemeID" schemeAgencyID="pvalue->ReferencedOrder.SellersOrderID.schemeAgencyID" schemeVersionID="pvalue->ReferencedOrder.SellersOrderID.schemeVersionID" schemeAgencySchemeID="pvalue->ReferencedOrder.SellersOrderID.schemeAgencySchemeID" schemeAgencySchemeAgencyID="pvalue->ReferencedOrder.SellersOrderID.schemeAgencySchemeAgencyID" schemeDataURI="pvalue->ReferencedOrder.SellersOrderID.schemeDataURI" schemeURI="pvalue->ReferencedOrder.SellersOrderID.schemeURI" UID="pvalue->ReferencedOrder.SellersOrderID.UID" UIDRef="pvalue->ReferencedOrder.SellersOrderID.UIDRef" UIDRefs="pvalue->ReferencedOrder.SellersOrderID.UIDRefs0" language="pvalue->ReferencedOrder.SellersOrderID.language">pvalue->ReferencedOrder.SellersOrderID</cat:SellersOrderID>
|
||||||
|
</cat:ReferencedOrder>
|
||||||
|
</Invoice>
|
Loading…
x
Reference in New Issue
Block a user