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>2011-10-22 03:04:33 +0400
committerJunio C Hamano <gitster@pobox.com>2011-10-22 03:04:33 +0400
commit207095063379065f2894c091c8909269a00ed44a (patch)
tree0e117b5b75a459622282fd65510b54978a2d2458 /builtin
parente75a59adfcc4fd048690e5b25f9a8c31d8011d53 (diff)
parent58a6a9cc4397477a7d8b620165e651028cc0e3c9 (diff)
Merge branch 'jk/maint-pack-objects-compete-with-delete'
* jk/maint-pack-objects-compete-with-delete: downgrade "packfile cannot be accessed" errors to warnings pack-objects: protect against disappearing packs
Diffstat (limited to 'builtin')
-rw-r--r--builtin/pack-objects.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/builtin/pack-objects.c b/builtin/pack-objects.c
index 2b18de5dc3..ba3705d1de 100644
--- a/builtin/pack-objects.c
+++ b/builtin/pack-objects.c
@@ -804,6 +804,10 @@ static int add_object_entry(const unsigned char *sha1, enum object_type type,
off_t offset = find_pack_entry_one(sha1, p);
if (offset) {
if (!found_pack) {
+ if (!is_pack_valid(p)) {
+ warning("packfile %s cannot be accessed", p->pack_name);
+ continue;
+ }
found_offset = offset;
found_pack = p;
}