diff --git a/src/validators/DTD/DTDElementDecl.cpp b/src/validators/DTD/DTDElementDecl.cpp index a9de99bb42d6df6d9921b173e3efb1e512ecf7a5..7bdf62aecb2a95fd5a09ad1f0c70cccf3e09e4ec 100644 --- a/src/validators/DTD/DTDElementDecl.cpp +++ b/src/validators/DTD/DTDElementDecl.cpp @@ -351,6 +351,9 @@ XMLContentModel* DTDElementDecl::createChildModel(const Grammar* grammar) const // Get the content spec node of the element const ContentSpecNode* specNode = getContentSpec(); + if(!specNode) + ThrowXML(RuntimeException, XMLExcepts::CM_UnknownCMSpecType); + // // Do a sanity check that the node is does not have a PCDATA id. Since, // if it was, it should have already gotten taken by the Mixed model.