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

Re: [PATCH] run_diff_files: do not look at uninitialized stat data

From
Junio C Hamano <gitster@pobox.com>
Date
May 15, 2014, 16:37 UTC
Message-ID
<xmqqsiobgfq9.fsf@gitster.dls.corp.google.com>
In-Reply-To
<20140514221306.GA5020@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 13 quoted lines
> Thanks for a thorough bug report. I was able to reproduce it. The
> ...
> -- >8 --
> Subject: run_diff_files: do not look at uninitialized stat data
> ...
> We can fix both by splitting the CE_VALID and regular code
> paths, and making sure only to look at the stat information
> in the latter. Furthermore, we push the declaration of our
> "struct stat" down into the code paths that actually set it,
> so we cannot accidentally access it uninitialized in future
> code.
>
> Signed-off-by: Jeff King <peff@peff.net>
Thanks for an excellent work, as always.  Will queue.
Previous: Jeff King
Message 3 of 3 in “Strange situation with --assume-unchanged and diff --find-copies-harder”
  1. Elliott CableMay 11, 2014
  2. run_diff_files: do not look at uninitialized stat dataJeff King, May 14, 2014
  3. Junio C HamanoMay 15, 2014

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.