You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by tn...@apache.org on 2001/05/28 22:54:06 UTC

cvs commit: xml-xerces/c/src/validators/DTD DTDScanner.cpp

tng         01/05/28 13:54:06

  Modified:    c/src/validators/DTD DTDScanner.cpp
  Log:
  Schema: allocate a fDTDValidator, fSchemaValidator explicitly to avoid wrong cast
  
  Revision  Changes    Path
  1.7       +3 -21     xml-xerces/c/src/validators/DTD/DTDScanner.cpp
  
  Index: DTDScanner.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/src/validators/DTD/DTDScanner.cpp,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- DTDScanner.cpp	2001/05/11 13:27:09	1.6
  +++ DTDScanner.cpp	2001/05/28 20:54:06	1.7
  @@ -56,6 +56,9 @@
   
   /*
    * $Log: DTDScanner.cpp,v $
  + * Revision 1.7  2001/05/28 20:54:06  tng
  + * Schema: allocate a fDTDValidator, fSchemaValidator explicitly to avoid wrong cast
  + *
    * Revision 1.6  2001/05/11 13:27:09  tng
    * Copyright update.
    *
  @@ -1602,27 +1605,6 @@
       if(!reuseGrammar) {
           if (fScanner->getValidationScheme() == XMLScanner::Val_Auto)
               fScanner->setDoValidation(true);
  -
  -        // set up the Validator if validating
  -        if(fScanner->getDoValidation()) {
  -            if (fScanner->getValidator()) {
  -                if (!fScanner->getValidator()->handlesDTD())
  -                {
  -                    // the fValidator is from user
  -                    if (fScanner->isValidatorFromUser())
  -                        ThrowXML(RuntimeException, XMLExcepts::Gen_NoDTDValidator);
  -                    else {
  -                        // the fValidator is created by the Scanner, replace it with proper Validator
  -                        fScanner->setValidator( new DTDValidator() );
  -                        fScanner->getValidator()->setGrammar(fDTDGrammar);
  -                    }
  -                }
  -            }
  -            else {
  -                fScanner->setValidator( new DTDValidator() );
  -                fScanner->getValidator()->setGrammar(fDTDGrammar);
  -            }
  -        }
       }
   
   
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-cvs-help@xml.apache.org