diff --git a/src/deptree.cpp b/src/deptree.cpp index bd8b8a2..f37b825 100644 --- a/src/deptree.cpp +++ b/src/deptree.cpp @@ -274,6 +274,7 @@ void TreeEvaluate(std::mutex* mtx, int* errflag, DepTree::LeafVector* leafs, con } mtx[1].unlock(); // End locked section + delete eob; leaf->parents.clear(); delete leaf; } @@ -364,6 +365,7 @@ void TreeEvaluate(int* errflag, DepTree::LeafVector* leafs) // If node have no children, it's a new leaf node if(0==i->childrens.size() && DepTree::ROOT!=i->type) leafs->push_back(i); } + delete eob; leaf->parents.clear(); delete leaf; }