tree
must be null
*ptree = NULL;