From: Jonathan Nieder Date: Wed, 19 Jan 2011 19:03:04 GMT Subject: Re: [PATCH 3/3] setup: always honor GIT_WORK_TREE and core.worktree Message-ID: <20110119190304.GA30618@burratino> In-Reply-To: <20110119124230.GD23222@burratino> Jonathan Nieder wrote: > --- a/setup.c > +++ b/setup.c > @@ -509,8 +532,10 @@ static const char *setup_git_directory_gently_1(int *nongit_ok) > * validation. > */ > gitdirenv = getenv(GIT_DIR_ENVIRONMENT); > - if (gitdirenv) > + if (gitdirenv) { > + trace_printf("trace: gitdirenv = %s\n", gitdirenv); > return setup_explicit_git_dir(gitdirenv, cwd, len, nongit_ok); > + } > The above hunk is a debugging remnant. I suppose it was foolish to send out the series so late. Probably not such a big deal since the problem Maaartin mentioned remains anyway (that is, the warning is still confusing). -- 8< -- Subject: fixup! setup: always honor GIT_WORK_TREE and core.worktree Remove noisy debug code. Signed-off-by: Jonathan Nieder --- diff --git b/setup.c a/setup.c index c0f5846..e08cdf2 100644 --- b/setup.c +++ a/setup.c @@ -532,10 +532,8 @@ static const char *setup_git_directory_gently_1(int *nongit_ok) * validation. */ gitdirenv = getenv(GIT_DIR_ENVIRONMENT); - if (gitdirenv) { - trace_printf("trace: gitdirenv = %s\n", gitdirenv); + if (gitdirenv) return setup_explicit_git_dir(gitdirenv, cwd, len, nongit_ok); - } ceil_offset = longest_ancestor_length(cwd, env_ceiling_dirs); if (ceil_offset < 0 && has_dos_drive_prefix(cwd))