summaryrefslogtreecommitdiff
path: root/include/git2/odb.h
diff options
context:
space:
mode:
authorMarc Pegon <pegon.marc@gmail.com>2011-05-28 21:24:25 +0200
committerVicent Marti <tanoku@gmail.com>2011-06-01 23:40:41 +0200
commitac2b94ad7658b53035b8518842348a083decd418 (patch)
tree19c5220d8493f697a4f09557ca4dfafb6cc12b36 /include/git2/odb.h
parentdd453c4dbf9a1fa38530b1f51e079852736b8f66 (diff)
downloadlibgit2-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.h5
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.
*