You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-users@xerces.apache.org by Yaron Kretchmer <YK...@altera.com> on 2005/09/22 15:36:37 UTC
Memory Manager
Hi All,
My program encapsulates all calls to Xerces in a
class.
XercesDOMParser is a member of the class. I create a
function to parse XML, traverse the DOMDocument and
create my internal data structure.
void parseFile ()
{
XMLPlatformUtils::Initialize();
{
// function that creates a DOMDocument by using XercesDOMParser
// function that traverse the DOMDocument and generate internal data
// structure
}
XMLPlatformUtils::Terminate();
}
However, I found that calling Terminate() does not
release all memory used in parsing. The only memory
usage left should only be my internal data structure.
Running Valgrind with memcheck reports that new()
operator has been overriden. And memory allocated with
the overriden new() consumed much more memory that it
should be.
How do I disable this new() and how do I free all
xerces's related memory?
I'm using Xerces 2.6.0 on Redhat Linux with g++ 3.3.2.
Thanks in advance.