summaryrefslogtreecommitdiff
path: root/plugins/NewXstatusNotify/src
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/NewXstatusNotify/src')
-rw-r--r--plugins/NewXstatusNotify/src/main.cpp14
1 files changed, 8 insertions, 6 deletions
diff --git a/plugins/NewXstatusNotify/src/main.cpp b/plugins/NewXstatusNotify/src/main.cpp
index 350f99f536..4a7dd0e047 100644
--- a/plugins/NewXstatusNotify/src/main.cpp
+++ b/plugins/NewXstatusNotify/src/main.cpp
@@ -991,13 +991,15 @@ void InitStatusList()
VOID CALLBACK ConnectionTimerProc(HWND hwnd, UINT uMsg, UINT_PTR idEvent, DWORD dwTime)
{
- if (uMsg == WM_TIMER)
- {
- char szProto[256];
- //We've received a timer message: enable the popups for a specified protocol.
+ if (uMsg == WM_TIMER) {
KillTimer(hwnd, idEvent);
- DWORD dwResult = (DWORD)GetAtomNameA((ATOM)idEvent, szProto, sizeof(szProto));
- if (dwResult) db_set_b(0, MODULE, szProto, 1);
+
+ //We've received a timer message: enable the popups for a specified protocol.
+ char szProto[256];
+ if ( GetAtomNameA((ATOM)idEvent, szProto, sizeof(szProto)) > 0) {
+ db_set_b(0, MODULE, szProto, 1);
+ DeleteAtom((ATOM)idEvent);
+ }
}
}