Lookup a tree object from the repository, given a prefix of its identifier (short id).
pointer to the looked up tree
the repo to use when locating the tree.
identity of the tree to locate.
the length of the short identifier
GIT_SUCCESS or an error code