Re: [PATCH 2/2] list-objects: only look at cmdline trees with edge_hint
- From
Jeff King <peff@peff.net>
- Date
- Jan 21, 2014, 02:22 UTC
- Message-ID
- <20140121022254.GA4597@sigill.intra.peff.net>
- In-Reply-To
- <CACsJy8CBuW0dXgbSLgFHye9-aCDQCaK47MFpqeCh3m3JWHJOEw@mail.gmail.com>
On Tue, Jan 21, 2014 at 06:57:08AM +0700, Duy Nguyen wrote:
> You must have so much fun (or headache, depending on your view) with > the variety of repos on github :)
It's fun on days like these when the solution is fairly straightforward. :)
Show 11 quoted lines
> > + if (revs->edge_hint) {
> > + for (i = 0; i < revs->cmdline.nr; i++) {
> > + struct object *obj = revs->cmdline.rev[i].item;
> > + struct commit *commit = (struct commit *)obj;
> > + if (obj->type != OBJ_COMMIT || !(obj->flags & UNINTERESTING))
> > + continue;
> > + mark_tree_uninteresting(commit->tree);
> > + if (revs->edge_hint && !(obj->flags & SHOWN)) {
>
> Not really important, but perhaps remove revs->edge_hint here because
> it's already checked?Yes, I think that is a good idea. Thanks.
Re-roll coming in a moment.
-Peff