git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Brandon Casey <drafnel@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org
Subject: Re: [PATCH v2 1/2] t7700: demonstrate repack flaw which may loosen  objects unnecessarily
Date: Sat, 21 Mar 2009 18:16:58 -0500	[thread overview]
Message-ID: <ee63ef30903211616pdf9fdal51dda518dd3cfec@mail.gmail.com> (raw)
In-Reply-To: <ee63ef30903211525q4a95a27eoa4e95c7954e5cc93@mail.gmail.com>

Man I just can't seem to get a patch off without issues.  I meant to
put these two comments in the patch emails.

1) Junio, these two patches are on top of 4d6acb70 which was the tip
of your jc/maint-1.6.0-keep-pack branch.

2) Also, note that this issue affects --keep-unreachable too, but the
fix is different since add_objects_in_unpacked_packs() just calls
add_object_entry() to add the unreachable objects to the list of
objects to pack and it (add_object_entry) already iterates on the pack
list.  One way to fix it, which feels very kludgy to me, is to
temporarily set 'local' to one before calling add_object_entry, so
that it will do nothing if the object is found in any non-local pack.
Unless I'm convinced it is worth it, I don't plan on fixing it.  I
doubt anyone uses --keep-unreachable manually.  It was invented to
make git-gc safe and has now been replaced by --unpack-unreachable.
So, --keep-unreachable may pack objects that it doesn't really need to
pack.  I can live with it.

-brandon


On Sat, Mar 21, 2009 at 5:25 PM, Brandon Casey <drafnel@gmail.com> wrote:
> If an unreferenced object exists in both a local pack and in either a pack
> residing in an alternate object database or a local kept pack, then the
> pack-objects call made by repack will loosen that object only to have it
> immediately pruned by repack's call to prune-packed.
>
> Signed-off-by: Brandon Casey <drafnel@gmail.com>
> ---

      reply	other threads:[~2009-03-21 23:18 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-03-21 22:25 [PATCH v2 1/2] t7700: demonstrate repack flaw which may loosen objects unnecessarily Brandon Casey
2009-03-21 23:16 ` Brandon Casey [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ee63ef30903211616pdf9fdal51dda518dd3cfec@mail.gmail.com \
    --to=drafnel@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).