diff options
author | Johannes Sixt <j6t@kdbg.org> | 2010-02-23 12:42:56 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2010-02-23 13:20:15 -0800 |
commit | aa0945701e39cf099ca9c28f79e239359781e4f6 (patch) | |
tree | 907d3d10e373473abb9ab18eaa6e5c78fbbf2c67 /exec_cmd.c | |
parent | e923eaeb901ff056421b9007adcbbce271caa7b6 (diff) | |
download | git-aa0945701e39cf099ca9c28f79e239359781e4f6.tar.gz git-aa0945701e39cf099ca9c28f79e239359781e4f6.tar.xz |
Print RUNTIME_PREFIX warning only when GIT_TRACE is set
When RUNTIME_PREFIX is enabled, the installation prefix is derived by
trying a limited set of known locations where the git executable can
reside. If none of these is found, a warning is emitted.
When git is built in a directory that matches neither of these known names,
the warning would always be emitted when the uninstalled executable is run.
This is a problem on Windows, where gitk picks the uninstalled git when
invoked from the build directory and gets confused by the warning.
Print the warning only when GIT_TRACE is set.
Signed-off-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'exec_cmd.c')
-rw-r--r-- | exec_cmd.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/exec_cmd.c b/exec_cmd.c index 408e4e55e..b2c07c70c 100644 --- a/exec_cmd.c +++ b/exec_cmd.c @@ -28,7 +28,7 @@ const char *system_path(const char *path) !(prefix = strip_path_suffix(argv0_path, BINDIR)) && !(prefix = strip_path_suffix(argv0_path, "git"))) { prefix = PREFIX; - fprintf(stderr, "RUNTIME_PREFIX requested, " + trace_printf("RUNTIME_PREFIX requested, " "but prefix computation failed. " "Using static fallback '%s'.\n", prefix); } |