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

Re: [RFC/PATCH] config.c: Make git_config() work correctly when called recursively

From
Ramsay Jones <ramsay@ramsay1.demon.co.uk>
Date
Jun 16, 2011, 19:55 UTC
Message-ID
<4DFA5FCD.6080902@ramsay1.demon.co.uk>
In-Reply-To
<20110614182726.GA451@sigill.intra.peff.net>
Jeff King wrote:
> On Tue, Jun 14, 2011 at 07:19:19PM +0100, Ramsay Jones wrote:
[...]
Show 10 quoted lines
>> I could, of course, have simply changed the expect file so that it would pass
>> the test, but I wanted the change to be self-contained and to pass all existing
>> tests (ie. the external interface/behaviour should *not* change).
> 
> No, you did the right thing here. The information on which config file
> we're in is valuable, and taking away the globals is not worth the pain
> of making all of the callers and callbacks of git_config have to deal
> with passing around a context struct.
> 
> So the patch you posted looks good to me.
Thanks! (I will abandon the search for an alternate solution! ;-)

I think the commit message needs to be re-worded before actually submitting the patch (it's fine for an RFC, but the call-chain info has a limited shelf life and should go).

Also, I wanted to re-submit two additional patches in that branch; last time they didn't even make it to pu! Hopefully they will take at least one step further this time.

ATB, Ramsay Jones

Previous: Jeff King
Message 5 of 5 in “config.c: Make git_config() work correctly when called recursively”
  1. config.c: Make git_config() work correctly when called recursivelyRamsay Jones, Jun 9, 2011
  2. Jeff KingJun 9, 2011
  3. Ramsay JonesJun 14, 2011
  4. Jeff KingJun 14, 2011
  5. Ramsay JonesJun 16, 2011

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.