All of lore.kernel.org
 help / color / mirror / Atom feed
From: Bojun Chen <bojun.cbj@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org, "Chen Bojun" <bojun.cbj@alibaba-inc.com>,
	"Ævar Arnfjörð Bjarmason" <avarab@gmail.com>,
	"Jiang Xin" <zhiyou.jx@alibaba-inc.com>,
	"Teng Long" <dyroneteng@gmail.com>
Subject: Re: [PATCH v2] receive-pack: purge temporary data if no command is ready to run
Date: Sat, 5 Feb 2022 15:19:22 +0800	[thread overview]
Message-ID: <CADuS7Apcr0r6F1UQf1WKmVuW+SM_wD1MBPA9Szvd1pF9zJjsUw@mail.gmail.com> (raw)
In-Reply-To: <xmqq5ypvpgzr.fsf@gitster.g>

Junio C Hamano <gitster@pobox.com> 于2022年2月4日周五 09:17写道:
>
> Chen BoJun <bojun.cbj@gmail.com> writes:
>
> > +     /*
> > +      * If there is no command ready to run, should return directly to destroy
> > +      * temporary data in the quarantine area.
> > +      */
> > +     for (cmd = commands; cmd && cmd->error_string; cmd = cmd->next)
> > +             ; /* nothing */
> > +     if (!cmd)
> > +             return;
> > +
> >       /*
> >        * Now we'll start writing out refs, which means the objects need
> >        * to be in their final positions so that other processes can see them.
>
> One thing I notice is that the first thing we do, after making the
> new objects available to us, is to check if we are making any
> conflicting update, e.g.
>
>     git push origin master:master next:master
>
> would try to update the same ref with different objects, and will be
> rejected.
>
> This check can _almost_ be doable without being able to access the
> new objects, and as a follow-on work, it might not be a bad little
> project to see how we can move the call to check_aliased_updates()
> before this loop we are adding in this patch (#leftoverbits).
>
> Thanks.

Thanks for your suggestion, I agree with you. But I'm confused should
I continue in this patch or start a new patch.

  reply	other threads:[~2022-02-05  7:19 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-24  1:26 [PATCH] receive-pack: purge temporary data if no command is ready to run BoJun via GitGitGadget
2022-01-24 15:17 ` Ævar Arnfjörð Bjarmason
2022-01-25 16:34   ` Lertz Chen
2022-01-24 23:32 ` Junio C Hamano
2022-01-25 16:49   ` Bojun Chen
2022-01-25  0:22 ` Jiang Xin
2022-01-29  6:35 ` [PATCH v2] " Chen BoJun
2022-02-01 22:51   ` Junio C Hamano
2022-02-01 23:27     ` Junio C Hamano
2022-02-05  7:17     ` Bojun Chen
2022-02-05  8:04       ` Junio C Hamano
2022-02-07  3:36       ` Jiang Xin
2022-02-07  8:02         ` Bojun Chen
2022-02-04  1:17   ` Junio C Hamano
2022-02-05  7:19     ` Bojun Chen [this message]
2022-02-05  8:02       ` Junio C Hamano
2022-02-07  7:57 ` [PATCH v3 0/1] " Chen BoJun
2022-02-07  7:57   ` [PATCH v3 1/1] receive-pack: " Chen BoJun

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=CADuS7Apcr0r6F1UQf1WKmVuW+SM_wD1MBPA9Szvd1pF9zJjsUw@mail.gmail.com \
    --to=bojun.cbj@gmail.com \
    --cc=avarab@gmail.com \
    --cc=bojun.cbj@alibaba-inc.com \
    --cc=dyroneteng@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=zhiyou.jx@alibaba-inc.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.