mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2026-01-26 21:41:34 +03:00
SAX2: Fix null deref after malloc failure
Short-lived regression.
This commit is contained in:
12
SAX2.c
12
SAX2.c
@@ -962,12 +962,12 @@ xmlSAX1Attribute(xmlParserCtxtPtr ctxt, const xmlChar *fullname,
|
||||
ns = NULL;
|
||||
xmlFree(name);
|
||||
name = xmlStrdup(fullname);
|
||||
if (name == NULL) {
|
||||
xmlSAX2ErrMemory(ctxt);
|
||||
if (ns != NULL)
|
||||
xmlFree(ns);
|
||||
return;
|
||||
}
|
||||
}
|
||||
if (name == NULL) {
|
||||
xmlSAX2ErrMemory(ctxt);
|
||||
if (ns != NULL)
|
||||
xmlFree(ns);
|
||||
return;
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
Reference in New Issue
Block a user