summaryrefslogtreecommitdiff
path: root/include/git2/odb_backend.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/git2/odb_backend.h')
-rw-r--r--include/git2/odb_backend.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/git2/odb_backend.h b/include/git2/odb_backend.h
index 04658f9b3..3963ae531 100644
--- a/include/git2/odb_backend.h
+++ b/include/git2/odb_backend.h
@@ -33,6 +33,7 @@ typedef int (*git_odb_foreach_cb)(const git_oid *id, void *payload);
* An instance for a custom backend
*/
struct git_odb_backend {
+ unsigned int version;
git_odb *odb;
/* read and read_prefix each return to libgit2 a buffer which
@@ -98,6 +99,9 @@ struct git_odb_backend {
void (* free)(struct git_odb_backend *);
};
+#define GIT_ODB_BACKEND_VERSION 1
+#define GIT_ODB_BACKEND_INIT {GIT_ODB_BACKEND_VERSION, 0}
+
/** Streaming mode */
enum {
GIT_STREAM_RDONLY = (1 << 1),