diff options
author | George Hazan <ghazan@miranda.im> | 2018-03-29 15:45:41 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-03-29 15:45:48 +0300 |
commit | 43fc37b844a3c9f32a2fda3fda751bbfdaa6a911 (patch) | |
tree | 4d99ad9523921fbc9af0f6ddfca63ad17bc06449 /plugins/DbEditorPP | |
parent | ac0c248abd4fa4befdbf4b44fb1c8483cadaefa4 (diff) |
fixes #1224 (Crash when launch in service mode)
Diffstat (limited to 'plugins/DbEditorPP')
-rw-r--r-- | plugins/DbEditorPP/src/main.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/plugins/DbEditorPP/src/main.cpp b/plugins/DbEditorPP/src/main.cpp index f72c886360..dcb399e72f 100644 --- a/plugins/DbEditorPP/src/main.cpp +++ b/plugins/DbEditorPP/src/main.cpp @@ -165,11 +165,13 @@ int PreShutdown(WPARAM, LPARAM) INT_PTR ServiceMode(WPARAM, LPARAM)
{
- IcoLibRegister();
- g_bServiceMode = true;
-
- HookEvent(ME_DB_CONTACT_SETTINGCHANGED, DBSettingChanged);
+ if (!g_bServiceMode) {
+ g_bServiceMode = true;
+ IcoLibRegister();
+ HookEvent(ME_DB_CONTACT_SETTINGCHANGED, DBSettingChanged);
+ }
+
return SERVICE_ONLYDB; // load database and then call us
}
|