You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by ra...@locus.apache.org on 2000/06/17 04:00:56 UTC

cvs commit: xml-xerces/c/src/parsers SAXParser.cpp

rahulj      00/06/16 19:00:55

  Modified:    c/src/parsers SAXParser.cpp
  Log:
  Also pass any PI's, comment's, character's occuring before root
  element to the registered document Handler. Defect identified
  by John Smirl and Rich Taylor.
  
  Revision  Changes    Path
  1.12      +3 -16     xml-xerces/c/src/parsers/SAXParser.cpp
  
  Index: SAXParser.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/src/parsers/SAXParser.cpp,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- SAXParser.cpp	2000/05/15 22:31:18	1.11
  +++ SAXParser.cpp	2000/06/17 02:00:55	1.12
  @@ -56,6 +56,11 @@
   
   /*
    * $Log: SAXParser.cpp,v $
  + * Revision 1.12  2000/06/17 02:00:55  rahulj
  + * Also pass any PI's, comment's, character's occuring before root
  + * element to the registered document Handler. Defect identified
  + * by John Smirl and Rich Taylor.
  + *
    * Revision 1.11  2000/05/15 22:31:18  andyh
    * Replace #include<memory.h> with <string.h> everywhere.
    *
  @@ -507,10 +512,6 @@
                                   , const unsigned int    length
                                   , const bool            cdataSection)
   {
  -    // SAX don't want to know about chars before content
  -    if (!fElemDepth)
  -        return;
  -
       // Just map to the SAX document handler
       if (fDocHandler)
           fDocHandler->characters(chars, length);
  @@ -526,10 +527,6 @@
   
   void SAXParser::docComment(const XMLCh* const commentText)
   {
  -    // SAX don't want to know about comments before content
  -    if (!fElemDepth)
  -        return;
  -
       //
       //  SAX has no way to report this. But, if there are any installed
       //  advanced handlers, then lets call them with this info.
  @@ -551,10 +548,6 @@
   void SAXParser::docPI(  const   XMLCh* const    target
                           , const XMLCh* const    data)
   {
  -    // SAX don't want to know about PIs before content
  -    if (!fElemDepth)
  -        return;
  -
       // Just map to the SAX document handler
       if (fDocHandler)
           fDocHandler->processingInstruction(target, data);
  @@ -621,10 +614,6 @@
                                       , const unsigned int    length
                                       , const bool            cdataSection)
   {
  -    // SAX don't want to know about space before content
  -    if (!fElemDepth)
  -        return;
  -
       // Just map to the SAX document handler
       if (fDocHandler)
           fDocHandler->ignorableWhitespace(chars, length);