fixed a leak in btree