X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=exec_cmd.c;h=171e841531de7fd5b51aa26f639104382395b854;hb=ee459baa5ce0a144e013a4995fd5be96bbecd05e;hp=408e4e55e1c58931444c772d35d23b505bf3e2ea;hpb=03f94ae9f909952ed5a78917ab319a312889354b;p=git.git diff --git a/exec_cmd.c b/exec_cmd.c index 408e4e55e..171e84153 100644 --- a/exec_cmd.c +++ b/exec_cmd.c @@ -3,7 +3,6 @@ #include "quote.h" #define MAX_ARGS 32 -extern char **environ; static const char *argv_exec_path; static const char *argv0_path; @@ -28,7 +27,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); } @@ -90,7 +89,7 @@ static void add_path(struct strbuf *out, const char *path) if (is_absolute_path(path)) strbuf_addstr(out, path); else - strbuf_addstr(out, make_nonrelative_path(path)); + strbuf_addstr(out, absolute_path(path)); strbuf_addch(out, PATH_SEP); } @@ -107,7 +106,7 @@ void setup_path(void) if (old_path) strbuf_addstr(&new_path, old_path); else - strbuf_addstr(&new_path, "/usr/local/bin:/usr/bin:/bin"); + strbuf_addstr(&new_path, _PATH_DEFPATH); setenv("PATH", new_path.buf, 1);