aboutsummaryrefslogtreecommitdiffstats
path: root/testSAX.c
diff options
context:
space:
mode:
authorDaniel Veillard <veillard@src.gnome.org>1999-08-10 19:04:08 +0000
committerDaniel Veillard <veillard@src.gnome.org>1999-08-10 19:04:08 +0000
commitb05deb7f5fa01da1cbc54f65199eff1c5421ec00 (patch)
tree88b82954fb85467ffd1ddad2d7dcaba7349bc32d /testSAX.c
parent6a6ccc1de6c19ff3c77c10491d5f8b65759cff4a (diff)
downloadandroid_external_libxml2-b05deb7f5fa01da1cbc54f65199eff1c5421ec00.tar.gz
android_external_libxml2-b05deb7f5fa01da1cbc54f65199eff1c5421ec00.tar.bz2
android_external_libxml2-b05deb7f5fa01da1cbc54f65199eff1c5421ec00.zip
Huge commit: 1.5.0, XML validation, Xpath, bugfixes, examples .... Daniel
Diffstat (limited to 'testSAX.c')
-rw-r--r--testSAX.c23
1 files changed, 22 insertions, 1 deletions
diff --git a/testSAX.c b/testSAX.c
index c64bc3cd..2b2e89bc 100644
--- a/testSAX.c
+++ b/testSAX.c
@@ -61,6 +61,7 @@ xmlSAXHandler emptySAXHandlerStruct = {
NULL, /* xmlParserWarning */
NULL, /* xmlParserError */
NULL, /* xmlParserError */
+ NULL, /* getParameterEntity */
};
xmlSAXHandlerPtr emptySAXHandler = &emptySAXHandlerStruct;
@@ -156,7 +157,10 @@ internalSubsetDebug(xmlParserCtxtPtr ctxt, const CHAR *name,
name, ExternalID, SystemID);
if ((ExternalID != NULL) || (SystemID != NULL)) {
- externalSubset = xmlSAXParseDTD(debugSAXHandler, ExternalID, SystemID);
+ externalSubset = xmlParseDTD(ExternalID, SystemID);
+ if (externalSubset != NULL) {
+ xmlFreeDtd(externalSubset);
+ }
}
}
@@ -209,6 +213,22 @@ getEntityDebug(xmlParserCtxtPtr ctxt, const CHAR *name)
return(NULL);
}
+/**
+ * getParameterEntityDebug:
+ * @ctxt: An XML parser context
+ * @name: The entity name
+ *
+ * Get a parameter entity by name
+ *
+ * Returns the xmlParserInputPtr
+ */
+xmlEntityPtr
+getParameterEntityDebug(xmlParserCtxtPtr ctxt, const CHAR *name)
+{
+ fprintf(stdout, "SAX.getParameterEntity(%s)\n", name);
+ return(NULL);
+}
+
/**
* entityDeclDebug:
@@ -541,6 +561,7 @@ xmlSAXHandler debugSAXHandlerStruct = {
warningDebug,
errorDebug,
fatalErrorDebug,
+ getParameterEntityDebug,
};
xmlSAXHandlerPtr debugSAXHandler = &debugSAXHandlerStruct;