You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by pe...@apache.org on 2004/03/03 00:21:37 UTC

cvs commit: xml-xerces/c/src/xercesc/util StringPool.cpp

peiyongz    2004/03/02 15:21:37

  Modified:    c/src/xercesc/util StringPool.cpp
  Log:
  eliminate leakage
  
  Revision  Changes    Path
  1.10      +8 -1      xml-xerces/c/src/xercesc/util/StringPool.cpp
  
  Index: StringPool.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/src/xercesc/util/StringPool.cpp,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- StringPool.cpp	29 Jan 2004 11:48:46 -0000	1.9
  +++ StringPool.cpp	2 Mar 2004 23:21:37 -0000	1.10
  @@ -56,6 +56,9 @@
   
   /*
    * $Log$
  + * Revision 1.10  2004/03/02 23:21:37  peiyongz
  + * eliminate leakage
  + *
    * Revision 1.9  2004/01/29 11:48:46  cargilld
    * Code cleanup changes to get rid of various compiler diagnostic messages.
    *
  @@ -316,7 +319,11 @@
           {
               XMLCh* stringData;
               serEng.readString(stringData);
  -            addNewEntry(stringData);            
  +            addNewEntry(stringData);
  +
  +            //we got to deallocate this string 
  +            //since stringpool will duplicate this string in the PoolElem and own that copy
  +            fMemoryManager->deallocate(stringData);
           }
       }
   }
  
  
  

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