git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: final git bisect step leads to: "fatal: you want to use way too much memory"

From
Junio C Hamano <gitster@pobox.com>
Date
Jun 16, 2016, 18:36 UTC
Message-ID
<xmqqporh3rqu.fsf@gitster.mtv.corp.google.com>
In-Reply-To
<20160616134742.GA25920@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 6 quoted lines
> Interesting. But `git show` on the commit in question (f216419e5) does
> not have any problems. It looks like bisect's internal "show the commit"
> code does not properly call setup_revisions() to finalize the "struct
> rev_info". That leaves the expand_tabs_in_log flag as "-1", which then
> ends up cast to an unsigned of 2^64 when we use it in a size
> computation.
Yuck
> And who knows what other bugs have been lurking there over the years;
> there are other flags that should be finalized by setup_revision(), too.
>
> This patch should fix it.
Looks sensible.
Show 12 quoted lines
> diff --git a/bisect.c b/bisect.c
> index 6d93edb..dc13319 100644
> --- a/bisect.c
> +++ b/bisect.c
> @@ -890,6 +890,7 @@ static void show_diff_tree(const char *prefix, struct commit *commit)
>  	if (!opt.diffopt.output_format)
>  		opt.diffopt.output_format = DIFF_FORMAT_RAW;
>  
> +	setup_revisions(0, NULL, &opt, NULL);
>  	log_tree_commit(&opt, commit);
>  }
>  
Previous: Jeff KingNext: Jeff King
Message 5 of 8 in “final git bisect step leads to: "fatal: you want to use way too much memory"”
  1. Markus TrippelsdorfJun 16, 2016
  2. Markus TrippelsdorfJun 16, 2016
  3. Markus TrippelsdorfJun 16, 2016
  4. Jeff KingJun 16, 2016
  5. Junio C HamanoJun 16, 2016
  6. bisect: always call setup_revisions after init_revisionsJeff King, Jun 16, 2016
  7. Junio C HamanoJun 17, 2016
  8. Jeff KingJun 17, 2016

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.