tool_main: make TerminalSettings static

Reported-by: Gisle Vanem
Bug: becfe1233f (commitcomment-31008819)
Closes #3161
This commit is contained in:
Daniel Stenberg 2018-10-23 13:38:48 +02:00
parent abfdf6a0b7
commit ae925ddcc3
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2
1 changed files with 5 additions and 5 deletions

View File

@ -238,16 +238,14 @@ static void main_free(struct GlobalConfig *config)
#ifdef _WIN32
/* TerminalSettings for Windows */
struct TerminalSettings {
static struct TerminalSettings {
HANDLE hStdOut;
DWORD dwOutputMode;
UINT nCodepage;
}TerminalSettings;
#endif
} TerminalSettings;
static void configure_terminal(void)
{
#ifdef _WIN32
/*
* If we're running Windows, enable VT output & set codepage to UTF-8.
* Note: VT mode flag can be set on any version of Windows, but VT
@ -273,8 +271,10 @@ static void configure_terminal(void)
TerminalSettings.dwOutputMode
| ENABLE_VIRTUAL_TERMINAL_PROCESSING);
}
#endif
}
#else
#define configure_terminal()
#endif
static void restore_terminal(void)
{