Almost done with contour tree, but memory leak.