Skip to content

Commit

Permalink
Merge pull request Mooophy#450 from clarelsy/patch-4
Browse files Browse the repository at this point in the history
Update ex13_28.cpp
  • Loading branch information
pezy committed May 4, 2016
2 parents dc7ed38 + faf6b92 commit 2f6a104
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions ch13/ex13_28.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,8 @@ TreeNode& TreeNode::operator=(const TreeNode &rhs)
{
++*rhs.count;
if (--*count == 0) {
if (left) {
delete left;
}
if (right) {
delete right;
}

delete left;
delete right;
delete count;
}
value = rhs.value;
Expand Down

0 comments on commit 2f6a104

Please sign in to comment.