1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2024-10-26 12:25:09 +03:00

xinclude: Report malloc failure in xmlXIncludeAddNode

This commit is contained in:
Nick Wellnhofer 2024-03-24 12:28:22 +01:00
parent ad9a5637f9
commit 1ace0e8529

View File

@ -521,8 +521,10 @@ xmlXIncludeAddNode(xmlXIncludeCtxtPtr ctxt, xmlNodePtr cur) {
base = NULL;
} else {
ref->base = xmlStrdup(BAD_CAST "");
if (ref->base == NULL)
if (ref->base == NULL) {
xmlXIncludeErrMemory(ctxt);
goto error;
}
}
}