Re: [PATCH] Sanity-ckeck config variable names
From: Jeff King <hidden>
Date: 2016-06-15 22:50:26
On Thu, Jan 20, 2011 at 06:22:32PM -0500, Jeff King wrote:
Other than that, the code looks OK to me.
Actually, I take this back. Doesn't this hunk:
quoted hunk ↗ jump to hunk
@@ -168,10 +167,6 @@ static int get_value(const char *key_, const char *regex_) } key = xstrdup(key_); - for (tl=key+strlen(key)-1; tl >= key && *tl != '.'; --tl) - *tl = tolower(*tl); - for (tl=key; *tl && *tl != '.'; ++tl) - *tl = tolower(*tl);
Mean that regexp keys no longer get downcased properly? I.e., git config Foo.value true git config --get-regexp 'foo.*' git config --get-regexp 'Foo.*' used to work for both lookups, but now fails for the second one? The problem is that your git_config_parse_key handles the downcasing for the non-regexp case, but it is not called (for obvious reasons) in the regexp case. -Peff