Que gerenciamento de memória preciso limpar ao usar o TinyXml for C +

Estou fazendo o seguinte com TinyXml:

TiXmlDocument doc;
TiXmlDeclaration* decl = new TiXmlDeclaration( "1.0", "", "" );
TiXmlElement* main = new TiXmlElement("main");

TiXmlElement* header = new TiXmlElement("header");
header->SetAttribute("attribute","somevalue");
main->LinkEndChild(header);

// ... Add many more TiXmlElment* to other elements all within "main" element

doc.LinkEndChild(decl);
doc.LinkEndChild(main);

// ... do stuff with doc

// Now I am done with my doc. What memory management happens here? 

No final da execução do meu programa, todos osTiXmlElement* seja limpo quando odoc sai do escopo? Preciso percorrer a árvore de documentos e liberar toda a memória pessoalmente?

questionAnswers(2)

yourAnswerToTheQuestion