Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
path: root/src/catch2
diff options
context:
space:
mode:
authorPino Toscano2024-10-18 23:18:19 +0200
committerMartin Hořeňovský2024-10-19 20:36:19 +0200
commita6ee7e20cd4011129816df7992c1a9db2ef4b58f (patch)
treef5ddf7cbcc0eb2ec1bcfeedc93783bb32b5b8737 /src/catch2
parent0b2af562710d1bac7fd32ca3f05bf1d713bb97e4 (diff)
downloadcatch3-a6ee7e20cd4011129816df7992c1a9db2ef4b58f.tar.gz
Use isatty() when using GNU libc
While isatty() is a POSIX interface and theoretically could be used more broadly than on Linux and macOS, use a conservative approach and use it on any platform that uses GNU libc.
Diffstat (limited to 'src/catch2')
-rw-r--r--src/catch2/internal/catch_console_colour.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/catch2/internal/catch_console_colour.cpp b/src/catch2/internal/catch_console_colour.cpp
index b19e01ec..142de9e6 100644
--- a/src/catch2/internal/catch_console_colour.cpp
+++ b/src/catch2/internal/catch_console_colour.cpp
@@ -161,7 +161,7 @@ namespace {
#endif // Windows/ ANSI/ None
-#if defined( CATCH_PLATFORM_LINUX ) || defined( CATCH_PLATFORM_MAC )
+#if defined( CATCH_PLATFORM_LINUX ) || defined( CATCH_PLATFORM_MAC ) || defined( __GLIBC__ )
# define CATCH_INTERNAL_HAS_ISATTY
# include <unistd.h>
#endif