Fix gen_tree initialization.