From: Junio C Hamano Date: Tue, 28 Jun 2016 15:42:33 GMT Subject: Re: [PATCH] Remove obsolete comment from color.h Message-ID: In-Reply-To: <16f3d3edb03c2cb9a6c11b745eda9fb2274af182.1467108142.git.johannes.schindelin@gmx.de> Johannes Schindelin writes: > Originally, ANSI color sequences were supported on Windows only by > overriding the printf() and fprintf() functions, as mentioned in e7821d7 > (Add a notice that only certain functions can print color escape codes, > 2009-11-27). > > As of eac14f8 (Win32: Thread-safe windows console output, 2012-01-14), > however, this is no longer the case, as the ANSI color sequence support > code needed to be replaced with a thread-safe version, one side effect > being that stdout and stderr handled no matter which function is used to > write to it. So as long as we write via stdio to stdout/stderr, you can show colors? Or is it now stronger, in that as long as we do anything that ends up writing to file descriptors 1 or 2, you can show colors? > So let's just remove the comment that is now obsolete. Thanks. > Signed-off-by: Johannes Schindelin > --- > Published-As: https://github.com/dscho/git/releases/tag/winansi-color-v1 > color.h | 5 ----- > 1 file changed, 5 deletions(-) > > diff --git a/color.h b/color.h > index e155d13..b9ead16 100644 > --- a/color.h > +++ b/color.h > @@ -18,11 +18,6 @@ struct strbuf; > */ > #define COLOR_MAXLEN 70 > > -/* > - * IMPORTANT: Due to the way these color codes are emulated on Windows, > - * write them only using printf(), fprintf(), and fputs(). In particular, > - * do not use puts() or write(). > - */ > #define GIT_COLOR_NORMAL "" > #define GIT_COLOR_RESET "\033[m" > #define GIT_COLOR_BOLD "\033[1m"