We'll raise an internal error and stop validation now when an entity is

* xmlschemas.c: We'll raise an internal error and stop
  validation now when an entity is found in the instance
  document, since we don't support automatic entity
  substitution by the schema processor (yet?) -
  see bug #340316, reported by Nick Wellnhofer.
diff --git a/xmlschemas.c b/xmlschemas.c
index 453a31c..6f8a39e 100644
--- a/xmlschemas.c
+++ b/xmlschemas.c
@@ -27496,8 +27496,13 @@
 	    (node->type == XML_ENTITY_REF_NODE)) {
 	    /*
 	    * DOC VAL TODO: What to do with entities?
-	    */
-	    TODO
+	    */	    
+	    VERROR_INT("xmlSchemaVDocWalk",
+		"there is at least one entity reference in the node-tree "
+		"currently being validated. Processing of entities with "
+		"this XML Schema processor is not supported (yet). Please "
+		"substitute entities before validation.");
+	    goto internal_error;
 	} else {
 	    goto leave_node;
 	    /*