diff options
author | George Hazan <ghazan@miranda.im> | 2019-03-31 22:31:57 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2019-03-31 22:31:57 +0300 |
commit | 19990d96d809a726de184724d94e0699536f6429 (patch) | |
tree | b545314b05c86718cc347f97f14a7acd78542248 /src | |
parent | 0b0a2259bf4580f60296087a08fd2b0bf4d05313 (diff) |
icon leak fixes
Diffstat (limited to 'src')
-rw-r--r-- | src/mir_app/src/ei_services.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/mir_app/src/ei_services.cpp b/src/mir_app/src/ei_services.cpp index cecff12090..65cab195c6 100644 --- a/src/mir_app/src/ei_services.cpp +++ b/src/mir_app/src/ei_services.cpp @@ -259,7 +259,7 @@ int ClistExtraClick(WPARAM hContact, LPARAM lParam) HANDLE hEventExtraImageListRebuilding, hEventExtraImageApplying, hEventExtraClick; static bool bImageCreated = false; -static HIMAGELIST hExtraImageList; +static HIMAGELIST hExtraImageList = nullptr; MIR_APP_DLL(HANDLE) ExtraIcon_AddIcon(HICON hIcon) { @@ -493,4 +493,9 @@ void UnloadExtraIconsModule(void) for (auto &it : registeredExtraIcons) delete it; + + if (hExtraImageList) { + ImageList_Destroy(hExtraImageList); + hExtraImageList = nullptr; + } } |