From 5df94ff719eccd04c7450df35fb5e3f2b36e2ee7 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sun, 13 Jul 2014 10:50:59 +0000 Subject: wrapping the most evident critical sections into a class git-svn-id: http://svn.miranda-ng.org/main/trunk@9785 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- src/modules/chat/chat_svc.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'src/modules/chat/chat_svc.cpp') diff --git a/src/modules/chat/chat_svc.cpp b/src/modules/chat/chat_svc.cpp index 1239b624b0..211e913d83 100644 --- a/src/modules/chat/chat_svc.cpp +++ b/src/modules/chat/chat_svc.cpp @@ -27,7 +27,7 @@ INT_PTR SvcGetChatManager(WPARAM, LPARAM); #include "chat.h" HGENMENU hJoinMenuItem, hLeaveMenuItem; -CRITICAL_SECTION cs; +mir_cs cs; static HANDLE hServiceRegister = NULL, @@ -583,8 +583,6 @@ static bool bInited = false; int LoadChatModule(void) { - InitializeCriticalSection(&cs); - HookEvent(ME_SYSTEM_MODULESLOADED, ModulesLoaded); HookEvent(ME_SYSTEM_PRESHUTDOWN, PreShutdown); HookEvent(ME_SKIN_ICONSCHANGED, IconsChanged); @@ -620,7 +618,6 @@ void UnloadChatModule(void) FreeMsgLogBitmaps(); OptionsUnInit(); - DeleteCriticalSection(&cs); DestroyHookableEvent(ci.hSendEvent); DestroyHookableEvent(ci.hBuildMenuEvent); -- cgit v1.2.3