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

Re: [PATCH] add_to_index(): convert forgotten HASH_RENORMALIZE check

From
Jeff King <peff@peff.net>
Date
Feb 7, 2019, 21:00 UTC
Message-ID
<20190207210009.GA30825@sigill.intra.peff.net>
In-Reply-To
<20190207041802.ai25fc64sqfg2h66@tb-raspi4>
On Thu, Feb 07, 2019 at 04:18:02AM +0000, Torsten Bögershausen wrote:
Show 11 quoted lines
> And trying to answer an older question:
> 
> >>>The reason appears to be wrong bit mask usage
> >>>#define ADD_CACHE_IGNORE_ERRORS    4
> >>>and
> >>>#define HASH_RENORMALIZE  4
> 
> What if we had renamed "flags" like this ?
> [...]
> -int add_to_index(struct index_state *istate, const char *path, struct stat *st, int flags)
> +int add_to_index(struct index_state *istate, const char *path, struct stat *st, int add_cache_flags)

Yes, changing the name of the variable in the original patch would have caught this case. I don't know if it is worth doing now or not (the code as it is now seems pretty clear to me, but of course I've looked at it a lot lately).

-Peff
Previous: Torsten BögershausenNext: Johannes Schindelin
Message 13 of 14 in “t0025 flakey?”
  1. Johannes SchindelinFeb 6, 2019
  2. SZEDER GáborFeb 6, 2019
  3. Johannes SchindelinFeb 6, 2019
  4. Torsten BögershausenFeb 6, 2019
  5. SZEDER GáborFeb 6, 2019
  6. Randall S. BeckerFeb 6, 2019
  7. Randall S. BeckerFeb 7, 2019
  8. Junio C HamanoFeb 7, 2019
  9. SZEDER GáborFeb 7, 2019
  10. Randall S. BeckerFeb 8, 2019
  11. add_to_index(): convert forgotten HASH_RENORMALIZE checkJeff King, Feb 7, 2019
  12. Torsten BögershausenFeb 7, 2019
  13. Jeff KingFeb 7, 2019
  14. Johannes SchindelinFeb 7, 2019

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.