Removed a stupid bug in xmlSchemaValidateAttributes, failing to build a
* xmlschemas.c: Removed a stupid bug in xmlSchemaValidateAttributes,
failing to build a linked list correctly (bug #169898, reported
by bing song, hmm...).
diff --git a/xmlschemas.c b/xmlschemas.c
index 55e26e5..35bd577 100644
--- a/xmlschemas.c
+++ b/xmlschemas.c
@@ -20243,15 +20243,12 @@
tmp->decl = attrDecl;
tmp->value = defValue;
tmp->next = NULL;
-
- if (defAttrStates == NULL) {
+ if (defAttrStatesTop == NULL)
defAttrStates = tmp;
- defAttrStates = tmp;
- } else {
- defAttrStates->next = tmp;
- defAttrStatesTop = tmp;
- }
- }
+ else
+ defAttrStatesTop->next = tmp;
+ defAttrStatesTop = tmp;
+ }
}
attrUse = attrUse->next;
}