1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-03-27 18:50:07 +03:00

fixed DEREF_AFTER_NULL.EX in xmlschemas.c. The problem was in line 13784 (neg = curWild->negNsSet->value;), where curWild->negNsSet could be NULL. Here's what the static analyzer writes: After having been compared to a NULL value at xmlschemas.c:13729, pointer 'curWild->negNsSet' is dereferenced at xmlschemas.c:13784.

This commit is contained in:
Anton Moryakov 2025-03-19 10:22:01 +00:00
parent dd4c0f62fa
commit c1c4447a9d

View File

@ -13780,7 +13780,7 @@ xmlSchemaIntersectWildcards(xmlSchemaParserCtxtPtr ctxt,
neg = completeWild->negNsSet->value;
if (xmlSchemaCloneWildcardNsConstraints(ctxt, completeWild, curWild) == -1)
return(-1);
} else
} else if (curWild->negNsSet != NULL)
neg = curWild->negNsSet->value;
/*
* Remove absent and negated.