Switch to unique_ptr for ownership clarity in places, combine more code.

This commit is contained in:
Ian Gulliver
2015-02-07 15:07:34 -08:00
parent 844db000f6
commit d82cb789e3
4 changed files with 56 additions and 71 deletions

2
tlv.h
View File

@@ -9,7 +9,7 @@ class TLVNode {
TLVNode(const uint16_t type, const std::string value);
~TLVNode();
static TLVNode* Decode(const std::string& input);
static std::unique_ptr<TLVNode> Decode(const std::string& input);
void AppendChild(TLVNode* child);