variable name changed, freeTree function changed