summaryrefslogtreecommitdiff
path: root/plugins/Console/src/Console.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2021-05-04 21:07:33 +0300
committerGeorge Hazan <ghazan@miranda.im>2021-05-04 21:07:33 +0300
commit45f973369d30ab01d92899d2ca6ca8371d284781 (patch)
tree1473751ff87725ff4f53be91032a32e8c75a854f /plugins/Console/src/Console.cpp
parent68c7bf3b55ca132143686ab433659c3b828760aa (diff)
compilation fix
Diffstat (limited to 'plugins/Console/src/Console.cpp')
-rw-r--r--plugins/Console/src/Console.cpp10
1 files changed, 2 insertions, 8 deletions
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);
}
////////////////////////////////////////////////////////////////////////////////