Use unique_ptr to store the XmlNode’s children

Also fix some constness things
This commit is contained in:
Florent Le Coz
2015-09-01 14:47:57 +02:00
parent 38564d77c7
commit f3b3d937ae
9 changed files with 69 additions and 71 deletions
+5
View File
@@ -111,6 +111,11 @@ private:
* new children, inner or tail)
*/
XmlNode* current_node;
/**
* The root node has no parent, so we keep it here: the XmppParser object
* is its owner.
*/
std::unique_ptr<XmlNode> root;
/**
* A list of callbacks to be called on an *_event, receiving the
* concerned Stanza/XmlNode.