summaryrefslogtreecommitdiff
path: root/src/core/stdaway
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/stdaway')
-rw-r--r--src/core/stdaway/awaymsg.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/core/stdaway/awaymsg.cpp b/src/core/stdaway/awaymsg.cpp
index 08d841275c..119fe411b4 100644
--- a/src/core/stdaway/awaymsg.cpp
+++ b/src/core/stdaway/awaymsg.cpp
@@ -158,13 +158,16 @@ static int AwayMsgPreBuildMenu(WPARAM wParam, LPARAM)
static int AwayMsgPreShutdown(WPARAM, LPARAM)
{
- if (hWindowList) WindowList_BroadcastAsync(hWindowList, WM_CLOSE, 0, 0);
+ if (hWindowList) {
+ WindowList_BroadcastAsync(hWindowList, WM_CLOSE, 0, 0);
+ WindowList_Destroy(hWindowList);
+ }
return 0;
}
int LoadAwayMsgModule(void)
{
- hWindowList = (HANDLE)CallService(MS_UTILS_ALLOCWINDOWLIST, 0, 0);
+ hWindowList = WindowList_Create();
CreateServiceFunction(MS_AWAYMSG_SHOWAWAYMSG, GetMessageCommand);
CLISTMENUITEM mi = { sizeof(mi) };