diff options
author | Kirill Volinsky <mataes2007@gmail.com> | 2015-04-30 19:34:57 +0000 |
---|---|---|
committer | Kirill Volinsky <mataes2007@gmail.com> | 2015-04-30 19:34:57 +0000 |
commit | 8757aa36a383c07cf5e946a4d95d8902bced1d76 (patch) | |
tree | d79ec42a134353cfd906c4af2564d4252e47cd90 /plugins/BasicHistory/src/Options.cpp | |
parent | a6ce02772dde52fd7b1de9d4b7ba6949c8b2316f (diff) |
minus critical section
git-svn-id: http://svn.miranda-ng.org/main/trunk@13312 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/BasicHistory/src/Options.cpp')
-rw-r--r-- | plugins/BasicHistory/src/Options.cpp | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/plugins/BasicHistory/src/Options.cpp b/plugins/BasicHistory/src/Options.cpp index f27278c14d..6307b9bffc 100644 --- a/plugins/BasicHistory/src/Options.cpp +++ b/plugins/BasicHistory/src/Options.cpp @@ -229,14 +229,8 @@ const int g_colorsSize = SIZEOF(g_ColorOptionsList); const int g_hotkeysSize = SIZEOF(g_HotkeyOptionsList);
-void Options::Unload()
-{
- DeleteCriticalSection(&criticalSection);
-}
-
void Options::Load(void)
{
- InitializeCriticalSection(&criticalSection);
FontIDT fid = {0};
ColourIDT cid = {0};
HOTKEYDESC hid = {0};
@@ -507,7 +501,7 @@ void Options::Save() void Options::SaveTasks(std::list<TaskOptions>* tasks)
{
- EnterCriticalSection(&criticalSection);
+ mir_cslock lck(criticalSection);
int oldTaskNr = (int)taskOptions.size();
taskOptions.clear();
int i = 0;
@@ -619,8 +613,6 @@ void Options::SaveTasks(std::list<TaskOptions>* tasks) for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact))
db_unset(hContact, MODULE, buf);
}
-
- LeaveCriticalSection(&criticalSection);
}
void Options::SaveTaskTime(TaskOptions& to)
|