Init the var too
This commit is contained in:
parent
f69062f68e
commit
1b19586681
1 changed files with 1 additions and 1 deletions
2
chat.cpp
2
chat.cpp
|
@ -889,7 +889,7 @@ int main(int argc, char ** argv) {
|
||||||
signal(SIGINT, sigint_handler);
|
signal(SIGINT, sigint_handler);
|
||||||
|
|
||||||
// Windows console ANSI color fix
|
// Windows console ANSI color fix
|
||||||
DWORD mode;
|
DWORD mode = 0;
|
||||||
HANDLE hConsole = GetStdHandle(STD_OUTPUT_HANDLE);
|
HANDLE hConsole = GetStdHandle(STD_OUTPUT_HANDLE);
|
||||||
if (hConsole && hConsole != INVALID_HANDLE_VALUE && GetConsoleMode(hConsole, &mode))
|
if (hConsole && hConsole != INVALID_HANDLE_VALUE && GetConsoleMode(hConsole, &mode))
|
||||||
SetConsoleMode(hConsole, mode | ENABLE_VIRTUAL_TERMINAL_PROCESSING);
|
SetConsoleMode(hConsole, mode | ENABLE_VIRTUAL_TERMINAL_PROCESSING);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue