You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by sa...@apache.org on 2003/05/14 21:24:17 UTC

cvs commit: xml-xerces/java/src/org/apache/xerces/impl XMLDTDScannerImpl.java

sandygao    2003/05/14 12:24:17

  Modified:    java/src/org/apache/xerces/impl XMLDTDScannerImpl.java
  Log:
  Fixing one infinite loop after fatal error.
  
  Revision  Changes    Path
  1.41      +12 -1     xml-xerces/java/src/org/apache/xerces/impl/XMLDTDScannerImpl.java
  
  Index: XMLDTDScannerImpl.java
  ===================================================================
  RCS file: /home/cvs/xml-xerces/java/src/org/apache/xerces/impl/XMLDTDScannerImpl.java,v
  retrieving revision 1.40
  retrieving revision 1.41
  diff -u -r1.40 -r1.41
  --- XMLDTDScannerImpl.java	8 May 2003 20:11:54 -0000	1.40
  +++ XMLDTDScannerImpl.java	14 May 2003 19:24:17 -0000	1.41
  @@ -1970,6 +1970,17 @@
               }
               else {
                   reportFatalError("MSG_MARKUP_NOT_RECOGNIZED_IN_DTD", null);
  +                // Skip the part in error
  +                int ch;
  +                do {
  +                    // Ignore the current character
  +                    fEntityScanner.scanChar();
  +                    // Skip any separators
  +                    skipSeparator(false, true);
  +                    // Keeping getting the next character,
  +                    // until it's one of the expected ones
  +                    ch = fEntityScanner.peekChar();
  +                } while (ch != '<' && ch != ']' && !XMLChar.isSpace(ch));
               }
               skipSeparator(false, true);
           }
  
  
  

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