From: Junio C Hamano <gitster@pobox.com>
To: Nicolas Pitre <nico@cam.org>
Cc: Jon Nelson <jnelson@jamponi.net>, git@vger.kernel.org
Subject: Re: [PATCH] fix pack.packSizeLimit and --max-pack-size handling
Date: Wed, 12 Nov 2008 09:46:31 -0800 [thread overview]
Message-ID: <7vk5b8q1l4.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <alpine.LFD.2.00.0811121109420.27509@xanadu.home> (Nicolas Pitre's message of "Wed, 12 Nov 2008 11:17:22 -0500 (EST)")
Nicolas Pitre <nico@cam.org> writes:
> First, pack.packSizeLimit and --max-pack-size didn't use the same base
> unit which was confusing. They both use MiB now.
>
> Also, if the limit was sufficiently low, having a single object written
> could bust the limit (by design), but caused the remaining allowed size
> to go negative for subsequent objects, which for an unsigned variable is
> a rather huge limit.
>
> Signed-off-by: Nicolas Pitre <nico@cam.org>
> ---
> @@ -1844,7 +1848,7 @@ static int git_pack_config(const char *k, const char *v, void *cb)
> return 0;
> }
> if (!strcmp(k, "pack.packsizelimit")) {
> - pack_size_limit_cfg = git_config_ulong(k, v);
> + pack_size_limit_cfg = git_config_ulong(k, v) * 1024 * 1024;
The fix to tweak the limit for subsequent split pack is a good thing to
have, but this change would break existing repositories where people
specified 20971520 (or worse yet "20m") to limit the size to 20MB.
I think --max-pack-size is what should be fixed to use git_parse_ulong()
to match the configuration, if you find the discrepancy disturbing.
next prev parent reply other threads:[~2008-11-12 17:48 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-12 15:12 pack.packSizeLimit and --max-pack-size not working? Jon Nelson
2008-11-12 16:17 ` [PATCH] fix pack.packSizeLimit and --max-pack-size handling Nicolas Pitre
2008-11-12 17:46 ` Junio C Hamano [this message]
2008-11-12 18:23 ` Nicolas Pitre
2008-11-12 21:23 ` Junio C Hamano
2008-11-12 17:58 ` Jon Nelson
2008-11-12 21:42 ` Nanako Shiraishi
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=7vk5b8q1l4.fsf@gitster.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=jnelson@jamponi.net \
--cc=nico@cam.org \
/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).