diff options
author | Martin Storsjö <martin@martin.st> | 2020-01-24 00:02:35 +0200 |
---|---|---|
committer | Martin Storsjö <martin@martin.st> | 2020-01-24 22:17:18 +0200 |
commit | cbb254cb4cfdc64e50b24c559bf1a52480196e47 (patch) | |
tree | 38111f184b7233c2b3762e33a3af36a967da8ac9 /tests | |
parent | e931119a41d0c48d1c544af89768b119b13feb4d (diff) | |
download | ffmpeg-cbb254cb4cfdc64e50b24c559bf1a52480196e47.tar.gz |
checkasm: Check HAVE_GETSTDHANDLE here as well
This was missed in 63418e374fcf26.
Signed-off-by: Martin Storsjö <martin@martin.st>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/checkasm/checkasm.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/checkasm/checkasm.c b/tests/checkasm/checkasm.c index bcbe775510..d67147ae6f 100644 --- a/tests/checkasm/checkasm.c +++ b/tests/checkasm/checkasm.c @@ -42,7 +42,7 @@ #include <io.h> #endif -#if HAVE_SETCONSOLETEXTATTRIBUTE +#if HAVE_SETCONSOLETEXTATTRIBUTE && HAVE_GETSTDHANDLE #include <windows.h> #define COLOR_RED FOREGROUND_RED #define COLOR_GREEN FOREGROUND_GREEN @@ -374,7 +374,7 @@ static void color_printf(int color, const char *fmt, ...) static int use_color = -1; va_list arg; -#if HAVE_SETCONSOLETEXTATTRIBUTE +#if HAVE_SETCONSOLETEXTATTRIBUTE && HAVE_GETSTDHANDLE static HANDLE con; static WORD org_attributes; @@ -403,7 +403,7 @@ static void color_printf(int color, const char *fmt, ...) va_end(arg); if (use_color) { -#if HAVE_SETCONSOLETEXTATTRIBUTE +#if HAVE_SETCONSOLETEXTATTRIBUTE && HAVE_GETSTDHANDLE SetConsoleTextAttribute(con, org_attributes); #else fprintf(stderr, "\x1b[0m"); |