Andrew's git
/
gitweb.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
commit
grep
author
committer
pickaxe
?
re
multi-pack-index: add 'verify' verb
[gitweb.git]
/
midx.c
diff --git
a/midx.c
b/midx.c
index f3e8dbc10820303436c07126b85d6024d2fb3e56..8b6c855d48298de3b89e2e952190e1b64ffbec07 100644
(file)
--- a/
midx.c
+++ b/
midx.c
@@
-928,3
+928,16
@@
void clear_midx_file(const char *object_dir)
free(midx);
}
+
+static int verify_midx_error;
+
+int verify_midx_file(const char *object_dir)
+{
+ struct multi_pack_index *m = load_multi_pack_index(object_dir, 1);
+ verify_midx_error = 0;
+
+ if (!m)
+ return 0;
+
+ return verify_midx_error;
+}