diff options
author | Karsten Blees <blees@dcon.de> | 2010-07-31 00:04:02 +0000 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2014-06-10 13:32:44 -0700 |
commit | 143e615270bd17dcef0d8e5751dacc496eff687d (patch) | |
tree | 00264af173b8d49d1c9ef2cc5ba80aa7c0ee49ce /t/t4013/diff.log_--root_--patch-with-stat_--summary_master | |
parent | Win32: support Unicode console output (diff) | |
download | tgif-143e615270bd17dcef0d8e5751dacc496eff687d.tar.xz |
Win32: detect console streams more reliably
GetStdHandle(STD_OUTPUT_HANDLE) doesn't work for stderr if stdout is
redirected. Use _get_osfhandle of the FILE* instead.
_isatty() is true for all character devices (including parallel and serial
ports). Check return value of GetConsoleScreenBufferInfo instead to
reliably detect console handles (also don't initialize internal state from
an uninitialized CONSOLE_SCREEN_BUFFER_INFO structure if the function
fails).
Signed-off-by: Karsten Blees <blees@dcon.de>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Stepan Kasal <kasal@ucw.cz>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t4013/diff.log_--root_--patch-with-stat_--summary_master')
0 files changed, 0 insertions, 0 deletions