mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-10-21 14:53:44 +03:00
Fixed a test for duplicate attributes: Non-prefixed attributes were
* parser.c: Fixed a test for duplicate attributes: Non-prefixed attributes were treated as being bound to the default namespace.
This commit is contained in:
@@ -1,3 +1,8 @@
|
|||||||
|
Fri Apr 29 11:27:37 CEST 2005 Kasimier Buchcik <libxml2-cvs@cazic.net>
|
||||||
|
|
||||||
|
* parser.c: Fixed a test for duplicate attributes: Non-prefixed
|
||||||
|
attributes were treated as being bound to the default namespace.
|
||||||
|
|
||||||
Tue Apr 19 17:51:32 CEST 2005 Kasimier Buchcik <libxml2-cvs@cazic.net>
|
Tue Apr 19 17:51:32 CEST 2005 Kasimier Buchcik <libxml2-cvs@cazic.net>
|
||||||
|
|
||||||
* xmlschemastypes.c: Fixed date-time related validation
|
* xmlschemastypes.c: Fixed date-time related validation
|
||||||
|
20
parser.c
20
parser.c
@@ -7787,13 +7787,19 @@ failed:
|
|||||||
* The attributes checkings
|
* The attributes checkings
|
||||||
*/
|
*/
|
||||||
for (i = 0; i < nbatts;i += 5) {
|
for (i = 0; i < nbatts;i += 5) {
|
||||||
nsname = xmlGetNamespace(ctxt, atts[i + 1]);
|
/*
|
||||||
if ((atts[i + 1] != NULL) && (nsname == NULL)) {
|
* The default namespace does not apply to attribute names.
|
||||||
xmlNsErr(ctxt, XML_NS_ERR_UNDEFINED_NAMESPACE,
|
*/
|
||||||
"Namespace prefix %s for %s on %s is not defined\n",
|
if (atts[i + 1] != NULL) {
|
||||||
atts[i + 1], atts[i], localname);
|
nsname = xmlGetNamespace(ctxt, atts[i + 1]);
|
||||||
}
|
if (nsname == NULL) {
|
||||||
atts[i + 2] = nsname;
|
xmlNsErr(ctxt, XML_NS_ERR_UNDEFINED_NAMESPACE,
|
||||||
|
"Namespace prefix %s for %s on %s is not defined\n",
|
||||||
|
atts[i + 1], atts[i], localname);
|
||||||
|
}
|
||||||
|
atts[i + 2] = nsname;
|
||||||
|
} else
|
||||||
|
nsname = NULL;
|
||||||
/*
|
/*
|
||||||
* [ WFC: Unique Att Spec ]
|
* [ WFC: Unique Att Spec ]
|
||||||
* No attribute name may appear more than once in the same
|
* No attribute name may appear more than once in the same
|
||||||
|
Reference in New Issue
Block a user