git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Jeff King <peff@peff.net>
To: Eric Wong <e@80x24.org>
Cc: Gargi Sharma <gs051095@gmail.com>, git@vger.kernel.org
Subject: Re: [PATCH v5] mru: Replace mru.[ch] with list.h implementation
Date: Mon, 22 Jan 2018 19:15:00 -0500	[thread overview]
Message-ID: <20180123001500.GD26357@sigill.intra.peff.net> (raw)
In-Reply-To: <20180122073701.h7fh7xrkmnzndzj7@untitled>

On Mon, Jan 22, 2018 at 07:37:01AM +0000, Eric Wong wrote:

> > --- a/packfile.c
> > +++ b/packfile.c
> > @@ -859,9 +859,8 @@ static void prepare_packed_git_mru(void)
> >  {
> >  	struct packed_git *p;
> >  
> > -	mru_clear(&packed_git_mru);
> 
> But the removed mru_clear needs to be replaced with:
> 
> +	INIT_LIST_HEAD(&packed_git_mru);
> 
> Otherwise, t3050 never finishes for me.

Good catch. One alternative is to just add any new packs to the end (or
beginning) of the mru list, instead of "resetting" it here. We can do
that because we know that prepare_packed_git() never drops list entries,
but only adds new ones.

I'm OK with it either way, though.

-Peff

      reply	other threads:[~2018-01-23  0:15 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-21  1:26 [PATCH v5] mru: Replace mru.[ch] with list.h implementation Gargi Sharma
2018-01-22  7:37 ` Eric Wong
2018-01-23  0:15   ` Jeff King [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

  List information: http://vger.kernel.org/majordomo-info.html

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

  git send-email \
    --in-reply-to=20180123001500.GD26357@sigill.intra.peff.net \
    --to=peff@peff.net \
    --cc=e@80x24.org \
    --cc=git@vger.kernel.org \
    --cc=gs051095@gmail.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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).