git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] Remove obsolete comment from color.h

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Jun 28, 2016, 10:02 UTC
Message-ID
<16f3d3edb03c2cb9a6c11b745eda9fb2274af182.1467108142.git.johannes.schindelin@gmx.de>

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 let's just remove the comment that is now obsolete.
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
---
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"
-- 
2.9.0.118.g0e1a633

base-commit: cf4c2cfe52be5bd973a4838f73a35d3959ce2f43
Next: Junio C Hamano
Message 1 of 5 in “Remove obsolete comment from color.h”
  1. Remove obsolete comment from color.hJohannes Schindelin, Jun 28, 2016
  2. Junio C HamanoJun 28, 2016
  3. Johannes SchindelinJun 28, 2016
  4. Junio C HamanoJun 28, 2016
  5. Jeff KingJun 28, 2016

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.