mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-08-07 06:43:02 +03:00
fixed #71740 NotationDecl with a required field missing Daniel
* valid.c SAX.c: fixed #71740 NotationDecl with a required field missing Daniel
This commit is contained in:
@@ -1,3 +1,8 @@
|
|||||||
|
Mon Feb 18 00:06:42 CET 2002 Daniel Veillard <daniel@veillard.com>
|
||||||
|
|
||||||
|
* valid.c SAX.c: fixed #71740 NotationDecl with a required field
|
||||||
|
missing
|
||||||
|
|
||||||
Sun Feb 17 23:45:40 CET 2002 Daniel Veillard <daniel@veillard.com>
|
Sun Feb 17 23:45:40 CET 2002 Daniel Veillard <daniel@veillard.com>
|
||||||
|
|
||||||
* check-xml-test-suite.py: improved the behaviour a bit as
|
* check-xml-test-suite.py: improved the behaviour a bit as
|
||||||
|
9
SAX.c
9
SAX.c
@@ -569,7 +569,14 @@ notationDecl(void *ctx, const xmlChar *name,
|
|||||||
"SAX.notationDecl(%s, %s, %s)\n", name, publicId, systemId);
|
"SAX.notationDecl(%s, %s, %s)\n", name, publicId, systemId);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (ctxt->inSubset == 1)
|
if ((publicId == NULL) && (systemId == NULL)) {
|
||||||
|
if ((ctxt->sax != NULL) && (ctxt->sax->error != NULL))
|
||||||
|
ctxt->sax->error(ctxt,
|
||||||
|
"SAX.notationDecl(%s) externalID or PublicID missing\n", name);
|
||||||
|
ctxt->valid = 0;
|
||||||
|
ctxt->wellFormed = 0;
|
||||||
|
return;
|
||||||
|
} else if (ctxt->inSubset == 1)
|
||||||
nota = xmlAddNotationDecl(&ctxt->vctxt, ctxt->myDoc->intSubset, name,
|
nota = xmlAddNotationDecl(&ctxt->vctxt, ctxt->myDoc->intSubset, name,
|
||||||
publicId, systemId);
|
publicId, systemId);
|
||||||
else if (ctxt->inSubset == 2)
|
else if (ctxt->inSubset == 2)
|
||||||
|
1
valid.c
1
valid.c
@@ -1628,6 +1628,7 @@ xmlAddNotationDecl(xmlValidCtxtPtr ctxt ATTRIBUTE_UNUSED, xmlDtdPtr dtd,
|
|||||||
if ((PublicID == NULL) && (SystemID == NULL)) {
|
if ((PublicID == NULL) && (SystemID == NULL)) {
|
||||||
xmlGenericError(xmlGenericErrorContext,
|
xmlGenericError(xmlGenericErrorContext,
|
||||||
"xmlAddNotationDecl: no PUBLIC ID nor SYSTEM ID\n");
|
"xmlAddNotationDecl: no PUBLIC ID nor SYSTEM ID\n");
|
||||||
|
return(NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Reference in New Issue
Block a user