update_tree_fix_tree