Commit 8993f572 authored by Eric Pouech's avatar Eric Pouech Committed by Alexandre Julliard

conhost: Reset console attribute upon exit in unix mode.

parent 0e6b21ef
......@@ -2859,9 +2859,18 @@ static int main_loop( struct console *console, HANDLE signal )
return 0;
}
static void teardown( struct console *console )
{
if (console->is_unix)
{
set_tty_attr( console, empty_char_info.attr );
tty_flush( console );
}
}
int __cdecl wmain(int argc, WCHAR *argv[])
{
int headless = 0, i, width = 0, height = 0;
int headless = 0, i, width = 0, height = 0, ret;
HANDLE signal = NULL;
WCHAR *end;
......@@ -2954,5 +2963,8 @@ int __cdecl wmain(int argc, WCHAR *argv[])
ShowWindow( console.win, (si.dwFlags & STARTF_USESHOWWINDOW) ? si.wShowWindow : SW_SHOW );
}
return main_loop( &console, signal );
ret = main_loop( &console, signal );
teardown( &console );
return ret;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment