aboutsummaryrefslogtreecommitdiffstats
path: root/SAX2.c
diff options
context:
space:
mode:
authorDaniel Veillard <veillard@src.gnome.org>2004-10-29 12:10:55 +0000
committerDaniel Veillard <veillard@src.gnome.org>2004-10-29 12:10:55 +0000
commiteff45a92da861195551a2050487fcca0492cac7c (patch)
tree57150d0cbf7f5a1750e4d7cab403b8335a11da03 /SAX2.c
parentc2f83d1fad48c4483f34213dcf6935e308e0c596 (diff)
downloadandroid_external_libxml2-eff45a92da861195551a2050487fcca0492cac7c.tar.gz
android_external_libxml2-eff45a92da861195551a2050487fcca0492cac7c.tar.bz2
android_external_libxml2-eff45a92da861195551a2050487fcca0492cac7c.zip
register xmlSchemaSetValidErrors, patch from Brent Hendricks in the
* python/libxml.c: register xmlSchemaSetValidErrors, patch from Brent Hendricks in the mailing-list * include/libxml/valid.h HTMLparser.c SAX2.c valid.c parserInternals.c: fix #156626 and more generally how to find out if a validation contect is part of a parsing context or not. This can probably be improved to make 100% sure that vctxt->userData is the parser context too. It's a bit hairy because we can't change the xmlValidCtxt structure without breaking the ABI since this change xmlParserCtxt information indexes. Daniel
Diffstat (limited to 'SAX2.c')
-rw-r--r--SAX2.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/SAX2.c b/SAX2.c
index cda9ac53..af36df9d 100644
--- a/SAX2.c
+++ b/SAX2.c
@@ -1562,7 +1562,7 @@ xmlSAX2StartElement(void *ctx, const xmlChar *fullname, const xmlChar **atts)
* If it's the Document root, finish the DTD validation and
* check the document root element for validity
*/
- if ((ctxt->validate) && (ctxt->vctxt.finishDtd == 0)) {
+ if ((ctxt->validate) && (ctxt->vctxt.finishDtd == XML_CTXT_FINISH_DTD_0)) {
int chk;
chk = xmlValidateDtdFinal(&ctxt->vctxt, ctxt->myDoc);
@@ -1571,7 +1571,7 @@ xmlSAX2StartElement(void *ctx, const xmlChar *fullname, const xmlChar **atts)
if (chk < 0)
ctxt->wellFormed = 0;
ctxt->valid &= xmlValidateRoot(&ctxt->vctxt, ctxt->myDoc);
- ctxt->vctxt.finishDtd = 1;
+ ctxt->vctxt.finishDtd = XML_CTXT_FINISH_DTD_1;
}
#endif /* LIBXML_VALID_ENABLED */
@@ -2132,7 +2132,7 @@ xmlSAX2StartElementNs(void *ctx,
* If it's the Document root, finish the DTD validation and
* check the document root element for validity
*/
- if ((ctxt->validate) && (ctxt->vctxt.finishDtd == 0)) {
+ if ((ctxt->validate) && (ctxt->vctxt.finishDtd == XML_CTXT_FINISH_DTD_0)) {
int chk;
chk = xmlValidateDtdFinal(&ctxt->vctxt, ctxt->myDoc);
@@ -2141,7 +2141,7 @@ xmlSAX2StartElementNs(void *ctx,
if (chk < 0)
ctxt->wellFormed = 0;
ctxt->valid &= xmlValidateRoot(&ctxt->vctxt, ctxt->myDoc);
- ctxt->vctxt.finishDtd = 1;
+ ctxt->vctxt.finishDtd = XML_CTXT_FINISH_DTD_1;
}
#endif /* LIBXML_VALID_ENABLED */
}