remove treenode remove error (maybe introduce memory leak)