From 45f973369d30ab01d92899d2ca6ca8371d284781 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Tue, 4 May 2021 21:07:33 +0300 Subject: compilation fix --- plugins/Console/src/Console.cpp | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'plugins/Console/src/Console.cpp') diff --git a/plugins/Console/src/Console.cpp b/plugins/Console/src/Console.cpp index 6bf70f4454..a874f8c4cd 100644 --- a/plugins/Console/src/Console.cpp +++ b/plugins/Console/src/Console.cpp @@ -894,7 +894,7 @@ static INT_PTR CALLBACK ConsoleDlgProc(HWND hwndDlg, UINT message, WPARAM wParam void __cdecl ConsoleThread(void*) { - MThreadHandle threadLock(hConsoleThread); + MThreadHandle threadLock(g_plugin.hConsoleThread); CoInitialize(nullptr); HWND hwnd = CreateDialog(g_plugin.getInst(), MAKEINTRESOURCE(IDD_CONSOLE), nullptr, ConsoleDlgProc); @@ -1180,8 +1180,6 @@ static int stringCompare(LOGWIN *lw1, LOGWIN *lw2) static UINT logicons[] = { IDI_EMPTY, IDI_ARROW, IDI_IN, IDI_OUT, IDI_INFO }; -static HANDLE hConsoleThread = nullptr; - void InitConsole() { int i; @@ -1222,21 +1220,17 @@ void InitConsole() void ShutdownConsole(void) { - int i; - List_Destroy(&lModules); if (gImg) ImageList_Destroy(gImg); - for (i = 0; i < _countof(hIcons); i++) + for (int i = 0; i < _countof(hIcons); i++) if (hIcons[i]) DestroyIcon(hIcons[i]); if (hwndConsole) EndDialog(hwndConsole, TRUE); - if (hConsoleThread) - WaitForSingleObject(hConsoleThread, INFINITE); } //////////////////////////////////////////////////////////////////////////////// -- cgit v1.2.3