mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-10-23 01:52:48 +03:00
parser: Avoid duplicate namespace errors
Don't report an extra attribute uniqueness error if a namespace is undeclared. This matches old behavior.
This commit is contained in:
6
parser.c
6
parser.c
@@ -9249,6 +9249,12 @@ next_attr:
|
||||
nameHashValue = ctxt->attallocs[j] | 0x80000000;
|
||||
|
||||
if (nsIndex == NS_INDEX_EMPTY) {
|
||||
/*
|
||||
* Prefix with empty namespace means an undeclared
|
||||
* prefix which was already reported above.
|
||||
*/
|
||||
if (aprefix != NULL)
|
||||
continue;
|
||||
nsuri = NULL;
|
||||
uriHashValue = URI_HASH_EMPTY;
|
||||
} else if (nsIndex == NS_INDEX_XML) {
|
||||
|
Reference in New Issue
Block a user