Re: [PATCH 04/40] Windows: Use the Windows style PATH separator ';'.
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Feb 28, 2008, 17:57 UTC
- Message-ID
- <7vhcftj75f.fsf@gitster.siamese.dyndns.org>
- In-Reply-To
- <1204138503-6126-5-git-send-email-johannes.sixt@telecom.at>
Johannes Sixt <johannes.sixt@telecom.at> writes:
Show 15 quoted lines
> diff --git a/exec_cmd.c b/exec_cmd.c > index e189cac..343545d 100644 > --- a/exec_cmd.c > +++ b/exec_cmd.c > @@ -37,7 +37,11 @@ static void add_path(struct strbuf *out, const char *path) > else > strbuf_addstr(out, make_absolute_path(path)); > > +#ifdef __MINGW32__ > + strbuf_addch(out, ';'); > +#else > strbuf_addch(out, ':'); > +#endif > } > }
If it were only these two places it might be Ok, but together with 10/40 you may want to do
#if WINDOWS
#define PATH_SEP ';'
#else
#define PATH_SEP ':'
#endifin a header so that the C files do not have to suffer.