Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2018-06-13 22:50:46 +0300
committerJunio C Hamano <gitster@pobox.com>2018-06-13 22:50:46 +0300
commit549ca8aa7ce73fa3d4d5daabc8929d09b92c4763 (patch)
tree3c98a07afad31265b01da6d226fa397a3d1e71d9 /builtin/index-pack.c
parent4d605b0f38775066be0eaed33c52e0b716035498 (diff)
parent3737746120d4e16b3a2b3431e34eeb3314edfa8c (diff)
Merge branch 'jk/index-pack-maint'
"index-pack --strict" has been taught to make sure that it runs the final object integrity checks after making the freshly indexed packfile available to itself. * jk/index-pack-maint: index-pack: correct install_packed_git() args index-pack: handle --strict checks of non-repo packs prepare_commit_graft: treat non-repository as a noop
Diffstat (limited to 'builtin/index-pack.c')
-rw-r--r--builtin/index-pack.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/builtin/index-pack.c b/builtin/index-pack.c
index 4ab31ed388..74fe2973e1 100644
--- a/builtin/index-pack.c
+++ b/builtin/index-pack.c
@@ -1482,8 +1482,12 @@ static void final(const char *final_pack_name, const char *curr_pack_name,
} else
chmod(final_index_name, 0444);
- if (do_fsck_object)
- add_packed_git(final_index_name, strlen(final_index_name), 0);
+ if (do_fsck_object) {
+ struct packed_git *p;
+ p = add_packed_git(final_index_name, strlen(final_index_name), 0);
+ if (p)
+ install_packed_git(the_repository, p);
+ }
if (!from_stdin) {
printf("%s\n", sha1_to_hex(hash));