Author: mukulg Date: Sat Apr 21 20:49:58 2012 New Revision: 1328735 URL: http://svn.apache.org/viewvc?rev=1328735&view=rev Log: committing the same fix on trunk, for the commit that was made a moment ago on the schema-dev-1.1 branch.
Modified: xerces/java/trunk/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java Modified: xerces/java/trunk/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java URL: http://svn.apache.org/viewvc/xerces/java/trunk/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java?rev=1328735&r1=1328734&r2=1328735&view=diff ============================================================================== --- xerces/java/trunk/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java (original) +++ xerces/java/trunk/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java Sat Apr 21 20:49:58 2012 @@ -2106,6 +2106,14 @@ public class XMLSchemaValidator xsiType = attributes.getValue(SchemaSymbols.URI_XSI, SchemaSymbols.XSI_TYPE); } + if (fCurrentType == null && xsiType != null && fElementDepth == 0) { + fXSIErrorReporter.fErrorReporter.reportError( + XSMessageFormatter.SCHEMA_DOMAIN, + "cvc-elt.1.a", + new Object[] { element.rawname }, + XMLErrorReporter.SEVERITY_ERROR); + } + // if no decl/type found for the current element if (fCurrentType == null && xsiType == null) { // if this is the validation root, report an error, because --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@xerces.apache.org For additional commands, e-mail: commits-h...@xerces.apache.org