summaryrefslogtreecommitdiff
path: root/protocols/VKontakte/src/vk_messages.cpp
diff options
context:
space:
mode:
authorSergey Bolhovskoy <elzorfox@ya.ru>2015-07-09 10:33:09 +0000
committerSergey Bolhovskoy <elzorfox@ya.ru>2015-07-09 10:33:09 +0000
commit21c6c7a7cb65e25d55cce54b6e097c797b66f95e (patch)
tree0c8485de41cf9c550d8e7ed930bf8ba9f6b0b3e4 /protocols/VKontakte/src/vk_messages.cpp
parent3f42d3319d2a3e404db524428300ab0a8a9540b2 (diff)
VKontakte:
add locks for timer and vk_Instances fix mark messages as read in multiaccaunt configuration fix duplicate events and news version bump git-svn-id: http://svn.miranda-ng.org/main/trunk@14514 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/VKontakte/src/vk_messages.cpp')
-rw-r--r--protocols/VKontakte/src/vk_messages.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/protocols/VKontakte/src/vk_messages.cpp b/protocols/VKontakte/src/vk_messages.cpp
index 657c56471b..a8970be976 100644
--- a/protocols/VKontakte/src/vk_messages.cpp
+++ b/protocols/VKontakte/src/vk_messages.cpp
@@ -126,6 +126,13 @@ void CVkProto::OnSendMessage(NETLIBHTTPREQUEST *reply, AsyncHttpRequest *pReq)
int CVkProto::OnDbEventRead(WPARAM hContact, LPARAM)
{
debugLogA("CVkProto::OnDbEventRead");
+ if (!hContact)
+ return 0;
+
+ CMString szProto(ptrA(db_get_sa(hContact, "Protocol", "p")));
+ if (szProto.IsEmpty() || szProto != m_szModuleName)
+ return 0;
+
if (m_iMarkMessageReadOn == markOnRead)
MarkMessagesRead(hContact);
return 0;