mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-07-28 00:21:53 +03:00
cleaned up the output of SAX tests, Daniel
This commit is contained in:
28
testHTML.c
28
testHTML.c
@ -143,20 +143,15 @@ void
|
||||
internalSubsetDebug(void *ctx, const xmlChar *name,
|
||||
const xmlChar *ExternalID, const xmlChar *SystemID)
|
||||
{
|
||||
/* xmlDtdPtr externalSubset; */
|
||||
|
||||
fprintf(stdout, "SAX.internalSubset(%s, %s, %s)\n",
|
||||
name, (ExternalID == NULL) ? "(null)" : ExternalID,
|
||||
(SystemID == NULL) ? "(null)" : SystemID);
|
||||
|
||||
/***********
|
||||
if ((ExternalID != NULL) || (SystemID != NULL)) {
|
||||
externalSubset = xmlParseDTD(ExternalID, SystemID);
|
||||
if (externalSubset != NULL) {
|
||||
xmlFreeDtd(externalSubset);
|
||||
}
|
||||
}
|
||||
***********/
|
||||
fprintf(stdout, "SAX.internalSubset(%s,", name);
|
||||
if (ExternalID == NULL)
|
||||
fprintf(stdout, " ,");
|
||||
else
|
||||
fprintf(stdout, " %s,", ExternalID);
|
||||
if (SystemID == NULL)
|
||||
fprintf(stdout, " )\n");
|
||||
else
|
||||
fprintf(stdout, " %s)\n", SystemID);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -372,8 +367,9 @@ startElementDebug(void *ctx, const xmlChar *name, const xmlChar **atts)
|
||||
fprintf(stdout, "SAX.startElement(%s", (char *) name);
|
||||
if (atts != NULL) {
|
||||
for (i = 0;(atts[i] != NULL);i++) {
|
||||
fprintf(stdout, ", %s='", atts[i++]);
|
||||
fprintf(stdout, "%s'", (atts[i] == NULL) ? "(null)" : atts[i]);
|
||||
fprintf(stdout, ", %s", atts[i++]);
|
||||
if (atts[i] != NULL)
|
||||
fprintf(stdout, "='%s'", atts[i]);
|
||||
}
|
||||
}
|
||||
fprintf(stdout, ")\n");
|
||||
|
Reference in New Issue
Block a user