diff options
author | Marc Pegon <pegon.marc@gmail.com> | 2011-05-28 21:24:25 +0200 |
---|---|---|
committer | Vicent Marti <tanoku@gmail.com> | 2011-06-01 23:40:41 +0200 |
commit | ac2b94ad7658b53035b8518842348a083decd418 (patch) | |
tree | 19c5220d8493f697a4f09557ca4dfafb6cc12b36 /include/git2/odb.h | |
parent | dd453c4dbf9a1fa38530b1f51e079852736b8f66 (diff) | |
download | libgit2-ac2b94ad7658b53035b8518842348a083decd418.tar.gz |
Added a GIT_OID_MINPREFIXLEN constant to define the minimum length allowed for oid prefixes (set to 4, like in git). Consequently updated some object lookup methods and their documentation.
Diffstat (limited to 'include/git2/odb.h')
-rw-r--r-- | include/git2/odb.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/include/git2/odb.h b/include/git2/odb.h index 483934ad3..6c08ade54 100644 --- a/include/git2/odb.h +++ b/include/git2/odb.h @@ -132,9 +132,10 @@ GIT_EXTERN(int) git_odb_read(git_odb_object **out, git_odb *db, const git_oid *i * This method queries all available ODB backends * trying to match the 'len' first hexadecimal * characters of the 'short_id'. - * The remaining bits (GIT_OID_HEXSZ-len)*4 bits of + * The remaining (GIT_OID_HEXSZ-len)*4 bits of * 'short_id' must be 0s. - * The prefix must be long enough to identify + * 'len' must be at least GIT_OID_MINPREFIXLEN, + * and the prefix must be long enough to identify * a unique object in all the backends; the * method will fail otherwise. * |