diff --git a/valid.c b/valid.c index ea47142c..289a96a8 100644 --- a/valid.c +++ b/valid.c @@ -3399,7 +3399,8 @@ int xmlValidateNotationUse(xmlValidCtxtPtr ctxt, xmlDocPtr doc, const xmlChar *notationName) { xmlNotationPtr notaDecl; - if ((doc == NULL) || (doc->intSubset == NULL)) return(-1); + if ((doc == NULL) || (doc->intSubset == NULL) || + (notationName == NULL)) return(-1); notaDecl = xmlGetDtdNotationDesc(doc->intSubset, notationName); if ((notaDecl == NULL) && (doc->extSubset != NULL))