1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2026-01-26 21:41:34 +03:00

SAX2: Report malloc failure in xmlCheckDefaultedAttributes

This commit is contained in:
Nick Wellnhofer
2024-02-20 12:32:17 +01:00
parent 67e475b78e
commit 7dc8600a7f

6
SAX2.c
View File

@@ -1304,8 +1304,10 @@ process_external_subset:
if (attr->prefix != NULL) {
fulln = xmlStrdup(attr->prefix);
fulln = xmlStrcat(fulln, BAD_CAST ":");
fulln = xmlStrcat(fulln, attr->name);
if (fulln != NULL)
fulln = xmlStrcat(fulln, BAD_CAST ":");
if (fulln != NULL)
fulln = xmlStrcat(fulln, attr->name);
} else {
fulln = xmlStrdup(attr->name);
}