From: "Björn Gustavsson" <bgustavsson@gmail.com>
To: Jeff King <peff@peff.net>
Cc: "git@vger.kernel.org" <git@vger.kernel.org>
Subject: Re: (Mosty harmless) protocol error when pushing
Date: Wed, 26 May 2010 07:58:29 +0200 [thread overview]
Message-ID: <AANLkTilc9-B79EhmmO2t-VsHFZdupQn8zX9LFYRrn5of@mail.gmail.com> (raw)
In-Reply-To: <20100525072824.GA19612@coredump.intra.peff.net>
2010/5/25 Jeff King <peff@peff.net>:
> diff --git a/builtin/receive-pack.c b/builtin/receive-pack.c
> index bb34757..c0a6a3b 100644
> --- a/builtin/receive-pack.c
> +++ b/builtin/receive-pack.c
> @@ -843,7 +843,20 @@ int cmd_receive_pack(int argc, const char **argv, const char *prefix)
> const char *argv_gc_auto[] = {
> "gc", "--auto", "--quiet", NULL,
> };
> - run_command_v_opt(argv_gc_auto, RUN_GIT_CMD);
> + struct child_process proc;
> +
> + memset(&proc, 0, sizeof(proc));
> + proc.no_stdin = 1;
> + proc.stdout_to_stderr = 1;
> + proc.err = use_sideband ? -1 : 0;
> + proc.git_cmd = 1;
> + proc.argv = argv_gc_auto;
> +
> + if (!start_command(&proc)) {
> + if (use_sideband)
> + copy_to_sideband(proc.err, -1, NULL);
> + finish_command(&proc);
> + }
> }
> if (auto_update_server_info)
> update_server_info(0);
>
> Unfortunately I can't actually test it. :)
Thanks!
Unfortunately, I was also unable to reproduce the problem,
so I can't test it either.
There is no easy way to force a GC on my repository at github,
so I tried to push to a local repository having too many loose
objects using the "file:" protocol but the problem did not occur
(i.e. the repository was auto packed but the protocol error did
not happen).
--
Björn Gustavsson, Erlang/OTP, Ericsson AB
next prev parent reply other threads:[~2010-05-26 5:58 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-25 6:51 (Mosty harmless) protocol error when pushing Björn Gustavsson
2010-05-25 7:28 ` Jeff King
2010-05-26 5:58 ` Björn Gustavsson [this message]
2010-05-27 11:33 ` Ilari Liusvaara
2010-05-27 15:12 ` Jeff King
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=AANLkTilc9-B79EhmmO2t-VsHFZdupQn8zX9LFYRrn5of@mail.gmail.com \
--to=bgustavsson@gmail.com \
--cc=git@vger.kernel.org \
--cc=peff@peff.net \
/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).