1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-07-30 22:43:14 +03:00

- valid.c: applied small patch from Gary Pennington, reindented

some part of the code.
Daniel
This commit is contained in:
Daniel Veillard
2001-05-04 15:21:12 +00:00
parent 3bbbe6fa2a
commit 377219233f
2 changed files with 148 additions and 141 deletions

View File

@ -1,3 +1,8 @@
Fri May 4 17:19:39 CEST 2001 Daniel Veillard <Daniel.Veillard@imag.fr>
* valid.c: applied small patch from Gary Pennington, reindented
some part of the code.
Thu May 3 13:10:43 CEST 2001 Daniel Veillard <Daniel.Veillard@imag.fr> Thu May 3 13:10:43 CEST 2001 Daniel Veillard <Daniel.Veillard@imag.fr>
* configure.in doc/xml.html doc/html/*: preparing for 2.3.8 * configure.in doc/xml.html doc/html/*: preparing for 2.3.8

12
valid.c
View File

@ -2007,8 +2007,8 @@ xmlAddRef(xmlValidCtxtPtr ctxt ATTRIBUTE_UNUSED, xmlDocPtr doc, const xmlChar *v
* Return the ref * Return the ref
*/ */
if(NULL == (ref_list = xmlHashLookup(table, value))) { if (NULL == (ref_list = xmlHashLookup(table, value))) {
if(NULL == (ref_list = xmlListCreate(xmlFreeRef, NULL))) { if (NULL == (ref_list = xmlListCreate(xmlFreeRef, NULL))) {
xmlGenericError(xmlGenericErrorContext, xmlGenericError(xmlGenericErrorContext,
"xmlAddRef: Reference list creation failed!\n"); "xmlAddRef: Reference list creation failed!\n");
return(NULL); return(NULL);
@ -2059,10 +2059,12 @@ xmlIsRef(xmlDocPtr doc, xmlNodePtr elem, xmlAttrPtr attr) {
attrDecl = xmlGetDtdAttrDesc(doc->intSubset, elem->name, attr->name); attrDecl = xmlGetDtdAttrDesc(doc->intSubset, elem->name, attr->name);
if ((attrDecl == NULL) && (doc->extSubset != NULL)) if ((attrDecl == NULL) && (doc->extSubset != NULL))
attrDecl = xmlGetDtdAttrDesc(doc->extSubset, elem->name, attrDecl = xmlGetDtdAttrDesc(doc->extSubset,
attr->name); elem->name, attr->name);
if ((attrDecl != NULL) && (attrDecl->atype == XML_ATTRIBUTE_IDREF)) if ((attrDecl != NULL) &&
(attrDecl->atype == XML_ATTRIBUTE_IDREF ||
attrDecl->atype == XML_ATTRIBUTE_IDREFS))
return(1); return(1);
} }
return(0); return(0);