Parse a NUL terminated hex formatted object id string into a git_oid.
The given string must be NUL terminated, and must be the hex size of the given object ID type - 40 characters for SHA1, 64 characters for SHA256.
To parse an incomplete object ID (an object ID prefix), or a sequence
of characters that is not NUL terminated, use git_oid_from_prefix.
input hex string
0 or an error code