From: Johannes Schindelin Date: Tue, 20 Jun 2006 07:45:53 +0000 (+0200) Subject: repo-config: Fix late-night bug X-Git-Tag: v1.4.1-rc1~15^2~1 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=92a28be0ce12a50e0e53268be99130c2ef504c7e;p=git.git repo-config: Fix late-night bug This bug was hidden by the "future-proofing" of the test. Sigh. When neither GIT_CONFIG nor GIT_CONFIG_LOCAL is set, do not use NULL, but $GIT_DIR/config. Instead of using $GIT_DIR/config when only GIT_CONFIG_LOCAL is set. Sorry. Signed-off-by: Johannes Schindelin Signed-off-by: Junio C Hamano --- diff --git a/repo-config.c b/repo-config.c index 03f108fe2..ab8f1afee 100644 --- a/repo-config.c +++ b/repo-config.c @@ -74,8 +74,6 @@ static int get_value(const char* key_, const char* regex_) const char *home = getenv("HOME"); local = getenv("GIT_CONFIG_LOCAL"); if (!local) - local = repo_config; - else local = repo_config = strdup(git_path("config")); if (home) global = strdup(mkpath("%s/.gitconfig", home));