Buggy code:
class XSDComplexTypeTraverser extends XSDAbstractParticleTraverser { private static final int GLOBAL_NUM = 11 ; private static XSParticleDecl fErrorContent = null ; private static XSWildcardDecl fErrorWildcard = null ; private static XSParticleDecl getErrorContent ( ) { } private static XSWildcardDecl getErrorWildcard ( ) { } private String fName = null ; private String fTargetNamespace = null ; private short fDerivedBy = XSConstants . DERIVATION_RESTRICTION ; private short fFinal = XSConstants . DERIVATION_NONE ; private short fBlock = XSConstants . DERIVATION_NONE ; private short fContentType = XSComplexTypeDecl . CONTENTTYPE_EMPTY ; private XSTypeDefinition fBaseType = null ; private XSAttributeGroupDecl fAttrGrp = null ; private XSSimpleType fXSSimpleType = null ; private XSParticleDecl fParticle = null ; private boolean fIsAbstract = false ; private XSComplexTypeDecl fComplexTypeDecl = null ; private XSAnnotationImpl [ ] fAnnotations = null ; private Object [ ] fGlobalStore = null ; private int fGlobalStorePos = 0 ; XSDComplexTypeTraverser ( XSDHandler handler , XSAttributeChecker gAttrCheck ) { } private static final boolean DEBUG = false ; private static final class ComplexTypeRecoverableError extends Exception { private static final long serialVersionUID = 6802729912091130335L ; Object [ ] errorSubstText = null ; Element errorElem = null ; ComplexTypeRecoverableError ( ) { } ComplexTypeRecoverableError ( String msgKey , Object [ ] args , Element e ) { } } XSComplexTypeDecl traverseLocal ( Element complexTypeNode , XSDocumentInfo schemaDoc , SchemaGrammar grammar ) { } XSComplexTypeDecl traverseGlobal ( Element complexTypeNode , XSDocumentInfo schemaDoc , SchemaGrammar grammar ) { } private XSComplexTypeDecl traverseComplexTypeDecl ( Element complexTypeDecl , String complexTypeName , Object [ ] attrValues , XSDocumentInfo schemaDoc , SchemaGrammar grammar ) { } private void traverseSimpleContent ( Element simpleContentElement , XSDocumentInfo schemaDoc , SchemaGrammar grammar ) throws XSDComplexTypeTraverser . ComplexTypeRecoverableError { } private void traverseComplexContent ( Element complexContentElement , boolean mixedOnType , XSDocumentInfo schemaDoc , SchemaGrammar grammar ) throws XSDComplexTypeTraverser . ComplexTypeRecoverableError { } private void mergeAttributes ( XSAttributeGroupDecl fromAttrGrp , XSAttributeGroupDecl toAttrGrp , String typeName , boolean extension , Element elem ) throws XSDComplexTypeTraverser . ComplexTypeRecoverableError { XSObjectList attrUseS = fromAttrGrp . getAttributeUses ( ) ; XSAttributeUseImpl duplicateAttrUse = null ; XSAttributeUseImpl oneAttrUse = null ; int attrCount = attrUseS . getLength ( ) ; for ( int i = 0 ; i < attrCount ; i ++ ) { oneAttrUse = ( ( XSAttributeUseImpl ) ( attrUseS . item ( i ) ) ) ; XSAttributeUse existingAttrUse = toAttrGrp . getAttributeUse ( oneAttrUse . fAttrDecl . getNamespace ( ) , oneAttrUse . fAttrDecl . getName ( ) ) ; if ( existingAttrUse == null ) { String idName = toAttrGrp . addAttributeUse ( oneAttrUse ) ; if ( idName != null ) { throw new XSDComplexTypeTraverser . ComplexTypeRecoverableError ( "ct-props-correct.5" , new Object [ ] { typeName , idName , oneAttrUse . fAttrDecl . getName ( ) } , elem ) ; } } else if ( existingAttrUse != oneAttrUse ) { if ( extension ) { <START_BUG> throw new XSDComplexTypeTraverser . ComplexTypeRecoverableError ( "ct-props-correct.4" , new Object [ ] { typeName , oneAttrUse . fAttrDecl . getName ( ) } , elem ) ; <END_BUG> } } } if ( extension ) { if ( ( toAttrGrp . fAttributeWC ) == null ) { toAttrGrp . fAttributeWC = fromAttrGrp . fAttributeWC ; } else if ( ( fromAttrGrp . fAttributeWC ) != null ) { toAttrGrp . fAttributeWC = toAttrGrp . fAttributeWC . performUnionWith ( fromAttrGrp . fAttributeWC , toAttrGrp . fAttributeWC . fProcessContents ) ; if ( ( toAttrGrp . fAttributeWC ) == null ) { throw new XSDComplexTypeTraverser . ComplexTypeRecoverableError ( "src-ct.5" , new Object [ ] { typeName } , elem ) ; } } } } private void processComplexContent ( Element complexContentChild , boolean isMixed , boolean isDerivation , XSDocumentInfo schemaDoc , SchemaGrammar grammar ) throws XSDComplexTypeTraverser . ComplexTypeRecoverableError { } private boolean isAttrOrAttrGroup ( Element e ) { } private void traverseSimpleContentDecl ( Element simpleContentDecl ) { } private void traverseComplexContentDecl ( Element complexContentDecl , boolean mixedOnComplexTypeDecl ) { } private String genAnonTypeName ( Element complexTypeDecl ) { } private void handleComplexTypeError ( String messageId , Object [ ] args , Element e ) { } private void contentBackup ( ) { } private void contentRestore ( ) { } private void addAnnotation ( XSAnnotationImpl annotation ) { } }

Fix:
reportSchemaError ( "ct-props-correct.4" , new Object [ ] { typeName , oneAttrUse . fAttrDecl . getName ( ) } , elem ) ;